• Log in or sign up for an account here: https://www.sythe.org/login

I don't know what this code's for

Deacon Frost

Grand Master

Banned
Joined
Jan 30, 2007
Sythe Gold
57
Messages
2,905
Age
36
Location
Anderson, IN
Code:
<?php
//$server="69.22.158.241";
function shorten($y) {
        switch($y) {
                case "Overall": return "Over";
                case "Attack": return "Att";
                case "Defence": return "Def";
                case "Strength": return "Str";
                case "Hitpoints": return "HP";
                case "Ranged": return "Range";
                case "Prayer": return "Pray";
                case "Magic": return "Mage";
                case "Cooking": return "Cook";
                case "Woodcutting": return "Woodcut";
                case "Fletching": return "Fletch";
                case "Fishing": return "Fish";
                case "Firemaking": return "Fire";
                case "Crafting": return "Craft";
                case "Smithing": return "Smith";
                case "Mining": return "Mining";
                case "Herblore": return "Herb";
                case "Agility": return "Agil";
                case "Thieving": return "Thieve";
                case "Slayer": return "Slayer";
                case "Farming": return "Farm";
                case "Runecraft": return "Rune";
                case "Construction": return "Const";

        }
}
$server="hiscore.runescape.com";
$type=$_GET['type'];
$name=$_GET['name'];
$regex="/<td align=\"left\"><a href=\"(.+?)\">\n([A-Za-z0-9]+?)\n<\/a><\/td>\n<td align=\"right\">([0-9,]+?)<\/td>\n<td align=\"right\">([0-9,]+?)<\/td>\n<td align=\"right\">([0-9,]+?)<\/td>\n<\/tr>/i";
$data="";
        $socket=fsockopen("64.90.181.252", 80, $errno, $errstr, 30);
        if (!$socket) {
                die("Sorry, an error occured: $errno [ $errstr ]");
        }
        else {
                $out = "GET /hiscorepersonal.ws?user1=$name HTTP/1.0\r\n";
                $out .= "Host: hiscore.runescape.com\r\n";
                $out .= "Connection: Close\r\n\r\n";
                fwrite($socket,$out);
                while (!feof($socket)) {
                        $data.=fgets($socket,4096);
                }
                fclose($socket);
                //flush out some shit
                //unset($out); unset($socket); unset($server); unset($type); unset($name);
                //parse the output
                preg_match_all($regex,$data,$m);
        $c=0;
        if ($type=="level") {
                foreach ($m[2] as $statname => $x) {
                        if ($c!=0) {
                        echo " | ";
                        }
                        $c++;
                        echo $x. ": " . $m[4][$statname];
                }
        }
        if ($type=="exp") {
                foreach ($m[2] as $statname => $x) {
                        if ($c!=0) {
                        echo " | ";
                        }
                        $c++;
                        echo $x. ": " . $m[5][$statname];
                }
        }
        if ($type=="rank") {
                foreach ($m[2] as $statname => $x) {
                        if ($c!=0) {
                        echo " | ";
                        }
                        $c++;
                        echo  $x. ": " . $m[3][$statname];
                }
        }

        }
        //unset($m); unset($regex); unset($data);

?>













i found that on http://de.pastebin.ca/292822, after I typed runescapes IP address in google
 
Le Monkey
PHP Shit Show 2k26
Potamus
Prove it!
Sythe Awards 2011 Winner
Tier 1 Prizebox
Tortoise Penis
Trole
UWotM8?
Wait, do you not have an Archer rank?
That looks like a PHP stat calculator.

Moving to Other Languages...
 
Where did you get this, yes I believe it is a stat calc )_) can get you how much xp you need for a certain stat
 
Like I said, I pinged runescape... got the IP address, typed the ip address into google (simply for kicks) and that site popped up..

really, how much EXP huh? I thought those weren't existant, so that means this probably doesn't work correct?

And if it does.. will someone elightment me as to how, and what to do :P..

At the site, however, they had the option to submit an edit for this code, so it looks to be put together by different people.
 
It's a high score lookup script. It just returns a string of statistics (like attack, defense, and strength levels) on whatever user the site visitor is interested in. It's not very well coded, so I doubt it still works.
 
looks like it gets the stats from runescape.
 
looks like it gets the stats from runescape.

Thanks captain obvious, that's been stated already! What we do without your 1337 skillz?

Anyways...

Find a host that supports php, upload that scripts through whatever they support with a .php extension, and open it up in your browser, and that should work.
 
Runescape Gamblingrunescape gambling
Back
Top