Here's the tutorial that he gave me (from the breedables pet thingie stickie)
Randomizers are script that allows, when linked into a signature like if you where posting an image, allow random images to be shown at each refresh. They are, thus, good way to show off many pets at once while keeping your signature in the 500x500 pixels limit. Many different ones exist, and ill post a few there along with how to set them up correctly without any problem.
However, I just want to make something clear. Scripts are awfully easy to bug up. I've explained how to do so without messing up, but I can understand things could happen. If you really are stuck and don't know what you did wrong, then pm me and ill'd check it out and see if something messed up. BUT. You need to show me that you read the post conpletely and tried to fix the problem. I don't have the time to set up everyone's randomizers. If I see that the problem is something I warned you to check out... at best, ill tell you to reread. At worst, I won't answer you at all. So please, please, PLEASE for the love of GOD, read completely before starting to edit ! And if you have a friend that knows how please go to them before you go to me. I don't have time to help everyone.
Without further ado...
1 : ASP
This script is probabely one of the most known since it was the one Relikk had up in her sticky, but since it was unstickyed some time ago I will repost it here. First, to use this script, you will need an host that support the execution of .asp scripts, like www.1asphost.com. Keep in mind that they tend to block direct-links during the weekend, so your randomizer might stop working then. I've yet to find another good, free asp host, so if someone knows one, please pm me and ill put it up here.
First of all, copy this code into NOTEPAD (Not Word. Not Wordpad. NOTEPAD. Mac users, whatever allows you to save as a specific extention, im not too knowledgeful in that area.) :
Code:
<%
Dim intNumber, intHow_many, intRandom
intHow_many = 4 ' Number of images to randomize
Randomize
intRandom = Rnd()
intNumber = Int(intHow_many*intRandom + 1)
Select Case intNumber
Case 1
Response.Redirect("http://sampleurl.com")
Case 2
Response.Redirect("http://sampleurl.com")
Case 3
Response.Redirect("http://sampleurl.com")
Case 4
Response.Redirect("http://sampleurl.com")
End Select %>
Now, to edit it... take this line :
Code:
intHow_many = 4 ' Number of images to randomize
And change the 4 to the number of images you want to randomize. Next... those lines :
Code:
Case 1
Response.Redirect("http://sampleurl.com")
Change the url for the url of one of the image. If you have more than 4 images, copy/paste that fragment and change the case number, like this :
Code:
Case 5
Response.Redirect("http://sampleurl.com")
And so on. Do not edit ANYTHING ELSE ! The rest need to stay as-is for the script to work !
After you make sure everything is okay, save as and save it as something like random.asp, using notepad's file type as any so that it doesn't add the .txt ending, and then the server would see it as a text file and it won't work. This is why Word won't work. I repeat. WORD WON'T WORK. (Can you tell im sick of getting PMs about it when I said it black on white to use Notepad ?)
Then, if you don't have one allready, register an account on www.1asphost.com . This should be pretty self-explainatory. Then upload the file, and direct link it in your signature like if you where simpely adding an image, like...
Code:
And everything should be fine. If you get a red x, then make sure the numbers match in the code, then make sure each case has their own numbers.
2. PHP
This is personally one of my favorite scripts, since you don't need to always go back and edit it, all you have to do is dump the images you want in a folder, and the script will pick it up. The two downside is to find a good host that runs php and allows you to direct-link, and the fact that you cannot put direct-links into the randomizer. All the images that show up HAVE to be in the specified folder, so its completely useless to monitor hatchings/growings, and you will need to save the new image each time for it to update. It also will only pick up the jpg, png, and gif file types. Trough why would anyone want to use a bmp in a randomizer is beyond me. o_O
First, copy this into Notepad :
Code:
/*
Based on code by Perpetual Dreamer and Alland.
Instructions:
Place all the files that you want into the directory of your choice,
which will be specified in the $path variable.
Then, just link to the script as a php file. Can be used in a site, such as

,
or a forum, using
Enjoy.
Rob
*/
//directory here (relative to script)
$path = 'random';
$i = 0;
$imgDir = opendir ($path);
while ( $file = readdir( $imgDir ) )
{
//checks that file is an image
$file_type = strrchr( $file, "." );
$is_image = eregi( "jpg|gif|png",$file_type );
if ( $file != '.' && $file != '..' && $is_image )
{ $images[$i++] = $file; }
}
closedir ($imgDir);
srand( (double) microtime()*1000000 );
$image_name = $path . '/' . $images[rand( 0,sizeof( $images ) -1 )];
$imgSize = GetImageSize( $image_name );
//ends script if no images found
if ( $i == 0 )
die();
//Display the image
readfile("$image_name");
?>
All you have to edit is the $path = 'random'; part. Random here is the name of the folder that will have the files. Just use whatever folder name you want, as long as that specific folder has the images you want to show up in the randomizer. I don't know if you can link to a folder on another host, since I've never tried it, so I don't recommand it. Save is as something like random.php
Once you found an host, create the directory you specified in the script, then upload the images you want randomized in it. Then upload the script and link it in you sig like you would for an image, exemple :
Code:
And everything should so smoothly.
Hope those tutorials where helpful, and feel free to ask questions ! Myself or someone else that knows scripts is sure to help.
Yes, it's big.
sweatdrop