PDA

View Full Version : Need Help With Status Sig Script?



Masterfood680
13-06-2008, 04:42 PM
Hey... I have just installed a Habbo Status Sig script on my site. It works fine but the only problem is the image won't show. I know it has something to do with a code(forget the name of the file) but I took a look at the php last night and it gave me something like

GET=profile.PNG or soemthing like that but the profile is a psd and it is also not in the upload folder. anyway here is the code:


<?php
header("Content-type: image/png");
include ('habboClass.php');
$habbo = $_GET['name'];
//Data Retrieval
$habboHome = new habboClass($habbo, 'com.au');
if ($habboHome->banned())
{
$im = imagecreatefrompng("banned.png");
}
elseif ($habboHome->pageprivate())
{
$im = imagecreatefrompng("private.png");
}
elseif (!$habboHome->actual())
{
$im = imagecreatefrompng("exist.png");
}
else
{
$im = imagecreatefrompng("profile.png");
$white = imagecolorallocate($im, 255, 255, 255);
$fontbold = "volterb.ttf";
$font = "volter.ttf";
imagettftext($im, 7, 0, 103.5, 28.5, $white, $fontbold, "Name:");
imagettftext($im, 7, 0, 149.5, 28.5, $white, $font, $habboHome->name());
$habboMotto = $habboHome->motto();
$habboMotto = eregi_replace("&gt;", ">", $habboMotto);
$habboMotto = eregi_replace("&lt;", "<", $habboMotto);
imagettftext($im, 7, 0, 103.5, 58.5, $white, $fontbold, "Motto:");
imagettftext($im, 7, 0, 149.5, 58.5, $white, $font, $habboMotto);
if ($habboHome->online())
{
$statusText = "Online";
}
else
{
$statusText = "Offline";
}
imagettftext($im, 7, 0, 240, 89, $white, $fontbold, "Status:");
imagettftext($im, 7, 0, 290, 89, $white, $font, $statusText);
$habboFigure = $habboHome->figure();
$habboFigure = imagecreatefromgif($habboFigure);
imagecopy($im, $habboFigure, 16, 18.5, 0, 0, 64, 106);
if($habboHome->badge()){
$habboBadge = $habboHome->badge();
$habboBadge = imagecreatefromgif($habboBadge);
$halfBadgeX = imagesx($habboBadge) / 2;
$halfBadgeY = imagesy($habboBadge) / 2;
$centerX = 127.5 - $halfBadgeX;
$centerY = 110.5 - $halfBadgeY;
imagecopy($im, $habboBadge, $centerX, $centerY, 0, 0, imagesx($habboBadge),
imagesy($habboBadge));
if($habboHome->groupbadge()){
$habboBadge = $habboHome->groupbadge();
$habboGBadge = imagecreatefromgif($habboBadge);
$halfGBadgeX = imagesx($habboGBadge) / 2;
$halfGBadgeY = imagesy($habboGBadge) / 2;
$centerX = 193.5 - $halfGBadgeX;
$centerY = 110.5 - $halfGBadgeY;
imagecopy($im, $habboGBadge, $centerX, $centerY, 0, 0, imagesx($habboGBadge),
imagesy($habboGBadge));

}
}
}
//Create Image
imagepng($im);
imagedestroy($im);
?>



[img=http://images.habboupload.com/1213377635.jpg] (http://habboupload.com)

Trinity
13-06-2008, 05:08 PM
It won't work with a psd, it has to be png.

--ss--
13-06-2008, 07:13 PM
First of all for the script to work your host must have both the Freetype and GD Library scripts enabled.
Secondly, I believe you haven't installed the .htaccess file which changes the url with the mod-rewrite function, making the path to the image/file incorrect ;).

Masterfood680
13-06-2008, 10:39 PM
@ Trinity: That's what I thought.
@ss the .htacess is installed.

Independent
13-06-2008, 10:51 PM
@ Trinity: That's what I thought.
@ss the .htacess is installed.GD, not HTAACCESS - their two different things.

Yes but you haven't installed GD?!

Masterfood680
14-06-2008, 06:01 AM
Would you mind teklling me the difference, I believe this is turned on by defauklt if not how Can I turn it on?

Want to hide these adverts? Register an account for free!