PDA

View Full Version : PHP - Display a habbos motto



Florx
21-12-2006, 12:52 PM
I would like a script that will display a habbos motto. I have the one that displays the habbos picture



<?php
header("Content-type: image/gif");
$habbo = $_GET['name'];
$domain = 'http://www.habbo.co.uk';
$content = file_get_contents($domain . '/home/'.$habbo);
$div_start = explode('<div class="profile-figure">', $content, 2);
$div_end = explode('</div>', $div_start[1], 2);
$img = trim($div_end[0]);
$img = preg_replace('/<img alt=\"(.*?)\" src=\"(.*?)\" \/>/', '$2', $img);
$imag = $domain.$img;
$im = imagecreatefromgif($imag);
imagegif($im);
imagedestroy($im);
?>

and the "habbos online" counter too


<?php
$page = file_get_contents("http://www.habbo.co.uk");
$start = explode('<div class="profile-motto">', $page, 2);
$end = explode('<div class="clear"></div></div>', $start[1], 2);
$amount = trim($end[0]);
echo "Motto: <b>$amount</b>";
?>
Can anybody help please?

Florx
21-12-2006, 01:34 PM
dm found it :) ty

Blinger1
21-12-2006, 09:58 PM
could you share it with us please? :)

-1.
22-12-2006, 12:02 PM
I coded these a while ago


Motto


<?php
$habbo = $_GET['name'];
$home = file_get_contents("http://www.habbohotel.co.uk/home/".$habbo);
$start = explode('<div class="profile-motto">', $home);
$end = explode('</div>', $start[1]);
$motto1 = trim($end[0]);
$motto = str_replace(' <div class="clear">','',$motto1);
echo $motto;
?>

D.O.B


<?php
$habbo = $_GET['name'];
$home = file_get_contents("http://www.habbohotel.co.uk/home/".$habbo);
$start = explode('<div class="birthday date">', $home);
$end = explode('</div>', $start[1]);
$date1 = trim($end[0]);
echo $date1;
?>

Dentafrice1
22-12-2006, 04:10 PM
I coded those lonnnngggg before you did.

Black_Apalachi
22-12-2006, 09:43 PM
Sorry for the nub question but how do you put these codes into am inage if you know what I mean. There is a certain programme I persume? :rolleyes:

Dentafrice1
22-12-2006, 09:56 PM
Like GD Image?

Blinger1
23-12-2006, 12:55 AM
I think he means like -1. 's signature

=gamemaster=
24-12-2006, 09:58 AM
Yeah, I would like to know as well, (for when i get new comp) :)

undercover.
26-12-2006, 11:18 PM
have someone code a PHP script to see the Badges from a User?

i think its a good idea

Dentafrice1
26-12-2006, 11:40 PM
No their is no badge DIV i dont think

omgDAN!
27-12-2006, 10:25 AM
No I tried making one for the badge but it wouldn't work because the badge isn't in a div.

Dentafrice1
27-12-2006, 01:17 PM
Just said that :P

Blob
27-12-2006, 01:44 PM
have someone code a PHP script to see the Badges from a User?

i think its a good idea

That could actually be possible.

Dentafrice1
27-12-2006, 01:45 PM
That could actually be possible.
I dont think so.

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