Jump to content
xisto Community
Sign in to follow this  
Saint_Michael

Yet Another Sig Rotator head of trap17.com gfx crew

Recommended Posts

i was looking sround game renders for filter stuff when i happen to find this script, this script basically reads the files in your folder. without you the user to provide links into the script.

step 1: create a index.php file with in your images folder. and then paste this code into it, then save now open the index file in your browser and you should see an image. if not pm or pst here and i will help you out.


<?php
if ($dir = opendir("."))
{
$list = buildimagearray($dir);
displayrandomimage($list);
}

// This function reads all the files in the current directory and adds all image files to the array $list[]
function buildimagearray($dir)
{
while (false !== ($file = readdir($dir)))
{
if (!is_dir($file) && getimagesize($file))
{
$list[] = $file;
}
}
return $list;
}

// This function selects a random image, determines the mime type, opens the file for reading,
// and then outputs the image
function displayrandomimage($list)
{
srand ((double) microtime() * 10000000);
$sig = array_rand ($list);

$size = getimagesize ($list[$sig]);
$fp = fopen($list[$sig], "rb");

if ($size && $fp)
{
header("Content-type: {$size['mime']}");
fpassthru($fp);
exit;
}
}
?>



Step 2:change your images folder like this images>images.png in order for the script to work properly

NOTEi had to make another copy of my gift folder in order for this to work due to the fact that those who had gift sigs from me could still be seen just as a image. but to get it rotating i had to change the folder into a png format to get it to work.


Step3: then paste this code below to get it working. mind you put our own url in their not mine


[IMG]http://forums.xisto.com/no_longer_exists/;

ON A SIDE NOTE MAKE SURE THE FORUM HAS PHP ACTIVATED OR IT WILL NOT WORK

as you see here im using this as my gift sig rotator





if i have to make any edits i will let you all know.

Share this post


Link to post
Share on other sites

-----I merged this post with the above tutorial since this doesn't really stand as a single tutorial, and it can be considered a follow up to this topic/the above tutorial-----szupie

 

 

<?phpHeader("Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0");Header("Expires: Thu, 19 Nov 1981 08:52:00 GMT");Header("Pragma: no-cache");Header("Content-Type: image/gif");srand((double)microtime()*1000000);readfile("http://forums.xisto.com/no_longer_exists/;
here is another script the only downside to this is that you only can sig rotate jpgs and and not png or gifs. well you could just change the jpg into one of them.

 

just follow the same steps in my other sig rotating scripts.

Edited by szupie (see edit history)

Share this post


Link to post
Share on other sites

Wow! Thank you soo much! I have been looking for one of these for ages... The one I used to use went down permanently and I haven't been able to track down another...

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | 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.