Discussion in 'General Discussion' started by SponX, Jul 15, 2005.
50 credits if someone can give me the code (not a site) for a sig rotator
Thanks <3 ^_^
Here is a better explanation of the random php tutorial
Step one: go to http://www.100webspace.com/signup.html and fill out the form (enter fake info if u want but put real e-mail). For "Pick up a domain name" choose "use a subdomain" and it doesn't matter what you choose for payment method since its free. When you are done filling out the form click Place the order.
Step two: They should send you an e-mail already giving your username and password. Use that information to log into your account. If you didn't recieve an e-mail check your "Spam" folder or try step one again.
Step three: When you are logged in, click on the button "File Manager". Now click on the word "www" and now click on the only folder that should be listed and it should be your subdomain.
Step four: At the bottom of the page you should see "New Folder", highlight it and enter "images" and click Create Folder. You have just created a new folder called "images", this is where you put all of your sigs. Click "images" to go inside the folder and start uploading your sigs by clicking "Browse...", choose your file, then click "Upload File(s)".
Step five: After uploading all of your sigs, click "Uplevel". Then at the bottom of the page where it says "New file", highlight the text and enter "random.php" then click "Create File". Now there should be a big text editor. Copy/Paste this code into the text box:
// Header info, forces no cache and image type of GIF
header("Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0");
header("Expires: Thu, 19 Nov 1981 08:52:00 GMT");
// Define the subdirectory to where we store the images..
$dir = "images";
// Set a random seed up
// Set our counter to 0
$i = 0;
// Open the images directory
$dirHandle = opendir($dir);
// Read in image filenames
while(($im = readdir($dirHandle)))
// Don't read in the 2 directories ".." and "."
if($im != ".." && $im != ".")
// Add that image filename to the array
$image[$i] = $im;
// Increment our counter
// Close the directory handle
// Create a random number from 0 to the size of the array
$n = rand(0,(count($image)-1));
// Read in a file and output it to the output buffer..
// If we can't for some reason use the error.gif file in the error directory
Then click "Save"
Step six: Now everything is set up and all you have to do is enter the url: www.yourwebsite.com/random.php and it should display a random sig in your "images" folder. Go to www.starcraftdream.com, log in and click User CP -> Edit Signature and type
hey u get the credits =P
eh lets hope so lol
or just put this in a notepad and than rename it index.php
make a folder called mysigs and than host it. the host needs php for this to work. than when u have a host do this:
PUT THE INDEX.PHP in the folder with your sigs u want to rotate.
/* Suho1004's PHP Sig Rotator V2.0 */
/* This script takes an inventory of all image files in a directory */
/* and displays one at random. All you need to do is save this code */
/* in a directory that contains your images (name it what you will, */
/* but make sure it has a ".php" extension). Then just link to this */
/* script to get your random image. */
/* I would recommend naming this file "index.php," and then you can */
/* just link to the directory itself (like I do in my example). */
/* Once you've read these instructions, feel free to delete them to */
/* cut down on the file size. I claim no rights to this code, which */
/* means you can do whatever you like with it. Have fun. */
/* Thanks to TP for the gentle nudging... */
if ($dir = opendir("."))
$list = buildimagearray($dir);
// This function reads all the files in the current directory and adds all image files to the array $list
while (false !== ($file = readdir($dir)))
if (!is_dir($file) && getimagesize($file))
$list = $file;
// This function selects a random image, determines the mime type, opens the file for reading,
// and then outputs the image
srand ((double) microtime() * 10000000);
$sig = array_rand ($list);
$size = getimagesize ($list[$sig]);
$fp = fopen($list[$sig], "rb");
if ($size && $fp)
my way gives u a way to host it thought...and i did it first! lol
haha dont worry nothing unfriendly against u. just for the credits . and if i do win ill give u 50 percent.
lol thats cool if he likes urs better and gives to u it aint no thang i gonna go to bed got up too early this morning peace bro...BTW sponx or whoever u were POST HERE!
This is how i do mine
haha u knoe what's funny, i followed that so basically its the same thing .
Separate names with a comma.