Jump to content

F0XTR0T

Members
  • Posts

    11
  • Joined

  • Last visited

    Never

Everything posted by F0XTR0T

  1. hey hey dont go there. i used quote tags this time. but anyways, got a solution to my problem?
  2. as you quote both of us, good one
  3. Yeah, im confused like i said, im not the best at this stuff
  4. it isnt really updated. i just changed a few things that i was were wrong <?php //Simple siggy example. header("Content-type: image/png");//tell the browser what content to expect. $url = "http://shadowscripting.org/iDungeon/makeSiggies/siggy.php?name=Gladly&5=siggy5.png&lite=true";//replace all spaces with "%20". $url1 ="http://hiscore.runescape.com/index_lite.ws?player=69b"; $str = file($url); $str1 = file($url1); $split = explode("|", $str[0]); $split1 = explode(",", $str1[0]); //casted to a float from a string, because you people botted more xp than 32-bit servers can hold in an integer! $tokens = (float)$split[0]; $xp = (float)$split[1]; $completed = (float)$split[2]; $time = (float)$split[3]; $rank = (float)$split[4]; $message = (float)$split[5]; $s1 = $split1[51]; $im = imagecreate(607, 162);//for this example, we'll create a blank image. $im = imagecreatefrompng("Gladly's Siggy.png");//use this to load a background image instead. imagealphablending($im, true); // setting alpha blending on - leave this in. imagesavealpha($im, true); // save alphablending setting - leave this alone too. $textColor = imagecolorallocate($im, 0, 0, 0);//set up a color to use for the text. $bkgColor = imagecolorallocate($im, 0, 0, 0);//set up a random color for the background. (Not needed if you use a background image) //fill the image background: imagefill($im, 0, 0, $bkgColor);//also not needed if you use a background image. imagettftext($im, 18, 0, 57, 200, $textColor, "./imagine_font.ttf", "".number_format($s1)); imagettftext($im, 18, 0, 120, 200, $textColor, "./imagine_font.ttf", "00"); imagettftext($im, 18, 0, 180, 200, $textColor, "./imagine_font.ttf", "00"); imagettftext($im, 18, 0, 250, 200, $textColor, "./imagine_font.ttf", "00"); imagettftext($im, 13, 0, 340, 152, $textColor, "./imagine_font.ttf", "".number_format($xp)); imagettftext($im, 13, 0, 340, 170, $textColor, "./imagine_font.ttf", "".number_format($tokens)); imagettftext($im, 13, 0, 340, 132, $textColor, "./imagine_font.ttf", "".number_format($completed)); imagettftext($im, 13, 0, 340, 116, $textColor, "./imagine_font.ttf", "".sec2hms($time)); imagepng($im);//output the image to the browser! imagedestroy($im);//clean it from the system memory. //you can ignore the below function. It's simply here to convert the time. function sec2hms ($sec, $padHours = true) { //Function in this example created by Coggla @ http://snipplr.com/view/4688/convert-seconds-to-hhmmss/ // You'll probably want to make your own function. $hms = ""; // there are 3600 seconds in an hour, so if we // divide total seconds by 3600 and throw away // the remainder, we've got the number of hours $hours = intval(intval($sec) / 3600); // add to $hms, with a leading 0 if asked for $hms .= ($padHours) ? str_pad($hours, 2, "0", STR_PAD_LEFT). ':' : $hours. ':'; // dividing the total seconds by 60 will give us // the number of minutes, but we're interested in // minutes past the hour: to get that, we need to // divide by 60 again and keep the remainder $minutes = intval(($sec / 60) % 60); // then add to $hms (with a leading 0 if needed) $hms .= str_pad($minutes, 2, "0", STR_PAD_LEFT). ':'; // seconds are simple - just divide the total // seconds by 60 and keep the remainder $seconds = intval($sec % 60); // add to $hms, again with a leading 0 if needed $hms .= str_pad($seconds, 2, "0", STR_PAD_LEFT); return $hms; } ?>
  5. Wow NICE! but i dont get why mine doesnt work but yours does. could you post the code you used in brackets so i could see it? Its making me monder on what i did wrong
  6. who has 71 not 51? and um, im stupid in php, could you post what you changed so i can learn. And idk how to make 000webhost private.
  7. Sorry about that, the link givin is to the wrong database. I updated my actual php without updating this one the real link is http://hiscore.runescape.com/index_lite.ws?player=69b which would still imply that 51 is the correct interger. let me make a few modifications to my php, and update the image. Edit: i tried with 51 and didnt float the numbers, and nothing.
  8. thats the image that im editing with php. if you notice the single 0 next to the ring, it is supposed to be a 89. what isnt working is well, the stat isnt getting added correctly, and it wont update like everything else is. lets be a little more specific. the "time ran, dungeons completed, total xp, and total tokens" are being updated by $url Everything else, will be updated by $url1 $url1 is what im having a problem with
  9. So im working on a code that is rather long i guess. the problem im having is that it needs to pull some information from 2 sites and load it on to a image. it will pull information from one site and load it correctly. but not for the second. <?php //Simple siggy example. header("Content-type: image/png");//tell the browser what content to expect. $url = "http://shadowscripting.org/iDungeon/makeSiggies/siggy.php?name=All%20Users&5=siggy5.png&lite=true";//replace all spaces with "%20". $url1 ="http://hiscore.runescape.com/index_lite.ws?player=zezima"; $str = file($url); $str1 = file($url1); $split = explode("|", $str[0]); $split1 = explode(",", $str1[0]); //casted to a float from a string, because you people botted more xp than 32-bit servers can hold in an integer! $tokens = (float)$split[0]; $xp = (float)$split[1]; $completed = (float)$split[2]; $time = (float)$split[3]; $rank = (float)$split[4]; $message = (float)$split[5]; $s1 = (float)$split1[49]; $im = imagecreate(607, 162);//for this example, we'll create a blank image. $im = imagecreatefrompng("Gladly's Siggy.png");//use this to load a background image instead. imagealphablending($im, true); // setting alpha blending on - leave this in. imagesavealpha($im, true); // save alphablending setting - leave this alone too. $textColor = imagecolorallocate($im, 0, 0, 0);//set up a color to use for the text. $bkgColor = imagecolorallocate($im, 0, 0, 0);//set up a random color for the background. (Not needed if you use a background image) //fill the image background: imagefill($im, 0, 0, $bkgColor);//also not needed if you use a background image. imagettftext($im, 18, 0, 57, 200, $textColor, "./imagine_font.ttf", "".number_format($s1)); imagettftext($im, 18, 0, 120, 200, $textColor, "./imagine_font.ttf", "00"); imagettftext($im, 18, 0, 180, 200, $textColor, "./imagine_font.ttf", "00"); imagettftext($im, 18, 0, 250, 200, $textColor, "./imagine_font.ttf", "00"); imagettftext($im, 13, 0, 340, 152, $textColor, "./imagine_font.ttf", "".number_format($xp)); imagettftext($im, 13, 0, 340, 170, $textColor, "./imagine_font.ttf", "".number_format($tokens)); imagettftext($im, 13, 0, 340, 132, $textColor, "./imagine_font.ttf", "".number_format($completed)); imagettftext($im, 13, 0, 340, 116, $textColor, "./imagine_font.ttf", "".sec2hms($time)); imagepng($im);//output the image to the browser! imagedestroy($im);//clean it from the system memory. //you can ignore the below function. It's simply here to convert the time. function sec2hms ($sec, $padHours = true) { //Function in this example created by Coggla @ http://snipplr.com/view/4688/convert-seconds-to-hhmmss/ // You'll probably want to make your own function. $hms = ""; // there are 3600 seconds in an hour, so if we // divide total seconds by 3600 and throw away // the remainder, we've got the number of hours $hours = intval(intval($sec) / 3600); // add to $hms, with a leading 0 if asked for $hms .= ($padHours) ? str_pad($hours, 2, "0", STR_PAD_LEFT). ':' : $hours. ':'; // dividing the total seconds by 60 will give us // the number of minutes, but we're interested in // minutes past the hour: to get that, we need to // divide by 60 again and keep the remainder $minutes = intval(($sec / 60) % 60); // then add to $hms (with a leading 0 if needed) $hms .= str_pad($minutes, 2, "0", STR_PAD_LEFT). ':'; // seconds are simple - just divide the total // seconds by 60 and keep the remainder $seconds = intval($sec % 60); // add to $hms, again with a leading 0 if needed $hms .= str_pad($seconds, 2, "0", STR_PAD_LEFT); return $hms; } ?> anyone see a problem?
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.