Hello,
I made this script because if i use the furnidata from habbo the hole catalogus is one mess.
This helps me and the catalogus is fine :)
It makes a furnidata.txt file dat you must use in your variable.
Bugs found? report it here, send a pm.PHP Code:
<?php
/*####################################
### Furnidata maker ###
### ###
### Made by J.J.P.(c) ###
### Date: 18-8-2010 / 16:00 ###
### ###
### Bugs please report it! ###
### @ragezone: Joopie ###
### ###
####################################*/
$dbuser = "username";
$dbpass = "password";
$dbhost = "localhost";
$database = "database";
$link = mysql_connect($dbhost, $dbuser, $dbpass);
$dbname = mysql_select_db($database, $link);
$oldfurnidata = file_get_contents("http://hotel-nl.habbo.com/gamedata/furnidata");
$newfurnidata = fopen("furnidata.txt", "w+");
$furnidata[] = "[";
$result = mysql_query("Select * From furniture");
while ($row = mysql_fetch_array($result, MYSQL_ASSOC))
{
$data[] = "[";
$data[] = chr(34) . $row['type'] . chr(34) . ",";
$data[] = chr(34) . $row['sprite_id'] . chr(34) . ",";
$data[] = chr(34) . $row['item_name'] . chr(34) . ",";
$strpos = strpos($oldfurnidata, $data[3]);
$strlen = strlen($data[3]);
$substr = substr($oldfurnidata, (($strpos + $strlen) + 1));
$strpos = strpos($substr, "]");
$substr = substr($substr, 0, $strpos);
$data[] = chr(34) . $substr;
$data[] = "]";
foreach($data as $value)
{
$furnirow .= $value;
}
$furnidata[] = $furnirow;
$furnirow = null;
$data = null;
}
$furnidata[] = "]";
foreach($furnidata as $value)
{
$putsfurnidata .= $value;
}
fputs($newfurnidata, $putsfurnidata);
fclose($newfurnidata);
mysql_close($link);
$oldfurnidata = null;
$furnidata = null;
$putsfurnidata = null;
?>



![[PHP] Furnidata maker](http://ragezone.com/hyper728.png)


