Home
| Links | Site Map | About Us | Contact Us | Add your code

 

PHP Code: PHP RuneScape stat function  Next Code

 you use it like this:

$variable = getStats("RussellReal");

and you will get a two dimensional array.

$variable[$skill][$aspect];

$aspect would be "Level" or "Exp" or "Rank"

so for example: $variable["Strength"]["Level"]; will return 89, which is RussellReals Strength Level :P

not really for looping through the values, unless you use foreachs like so:

foreach ($variable as $skill => $v) {
$line = $skill;
foreach ($variable[$skill] as $aspect => $data) {
$line .= " ".$aspect.": ".$data;
}
echo $line."\n";
}
will print a readable version of the multidimensional array. :)
will return "false" if the username doesn't exist. and somewhere in the aspects of the second dimension of the arrays will be Not Ranked. for whichever skill the user isn't ranked in.

 

Preview:

 

 

 

 

 

 

Free Code Script:

Get Free Java, HTML, PHP codes and scripts. Use code script and easily with HTML and web help and samples. Learn Javascript, HTML and PHP source code, function, forms, website, forum, design for webmasters.

Link Us:

Free Code Script

Just put this code to your pages and you will have our logo in your site! This brings traffic to your website.

Favorite Us!


We update weekly!

Visitors:

Online Users:


Go to the main page

  Home | Links | Site Map | About Us | Contact Us | Add your code
2008 © Krishna Eydat, YOU MUST NOT remove the link to our website in any code, it is against the copyright law.