Jump to content

Looking for a PHP script (concerning sigs)


Xander6669

Recommended Posts

Yes I am looking for a PHP script one of the Tip.It mods or admins had on scapeboard. He would have in his signature something like this:

 

 

 

 

 

 

 

[img=http://blahblah.com/signature.php]

 

 

 

This file, signature.php, would make it so his signature changes every time it is loaded. Which means you would go on a topic and see one of the guy's signatures, and if you'd refresh the page, he would have another signature, and so on....

 

 

 

 

 

 

 

If anyone knows the script, or if you know what mod/admin had this script, please tell me. Thanks.

Link to comment
Share on other sites

Remember.. google is your friend

 

 

 

 

 

 

 




<?php



/*



   By Matt Mullenweg > http://photomatt.net



   Inspired by Dan Benjamin > http://hiveware.com/imagerotator.php



   Latest version always at:



   http://photomatt.net/scripts/randomimage



*/







// Make this the relative path to the images, like "../img" or "random/images/".



// If the images are in the same directory, leave it blank.



$folder = '';







// Space seperated list of extensions, you probably won't have to change this.



$exts = 'jpg jpeg png gif';







$files = array(); $i = -1; // Initialize some variables



if ('' == $folder) $folder = './';



$handle = opendir($folder);



$exts = explode(' ', $exts);



while (false !== ($file = readdir($handle))) {



   foreach($exts as $ext) { // for each extension check the extension



       if (preg_match('/\.'.$ext.'$/i', $file, $test)) { // faster than ereg, case insensitive



           $files[] = $file; // it's good



           ++$i;



           }



       }



   }



closedir($handle); // We're not using it anymore



mt_srand((double)microtime()*1000000); // seed for PHP < 4.2



$rand = mt_rand(0, $i); // $i was incremented as we went along







header('Location: '.$folder.$files[$rand]); // Voila!



?>



 

 

 

 

 

 

 

;)

 

 

 

That makes a random choice of images. Is there a way to make it not random, but instead it shows them one after another? So that way it doesn't end up featuring the same sig 50 times in a row randomly.

Link to comment
Share on other sites

I believe, that it was Mercifull that had that. And he was a private board moderator, not a real moderator ;)
Merc was the original writer of a script, but by the end of scape, many many users had randomized sigs, including myself. Php sigs are, however, no longer avaliable because they were a(nother) security risk. Many people are currently working on a random sig that poses no such risk, and ends in a conventional filename.
Link to comment
Share on other sites

 

I believe, that it was Mercifull that had that. And he was a private board moderator, not a real moderator ;)
Merc was the original writer of a script, but by the end of scape, many many users had randomized sigs, including myself. Php sigs are, however, no longer avaliable because they were a(nother) security risk. Many people are currently working on a random sig that poses no such risk, and ends in a conventional filename.

 

 

 

 

 

 

 

Including myself. muahahahaha

 

 

 

Ill post my old source code later so people can have a look. it wont work here anymore tho so you'll have to make it work yourself.

612d9da508.png

Mercifull.png

Mercifull <3 Suzi

"We don't want players to be able to buy their way to success in RuneScape. If we let players start doing this, it devalues RuneScape for others. We feel your status in real-life shouldn't affect your ability to be successful in RuneScape" Jagex 01/04/01 - 02/03/12

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.