GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   Script to rotate images? Any good one? (https://gfy.com/showthread.php?t=606545)

tranza 05-06-2006 09:30 AM

Script to rotate images? Any good one?
 
Do you guys know any script to rotate pictures AND the links of those pictures (each picture should have it own unique link)?

Anybody can help me out?

Dirty F 05-06-2006 09:31 AM

http://www.disbealig.com/_images/_da..._dapics_10.jpg

tranza 05-06-2006 09:43 AM

Stop posting your picture on every thread Franck

psili 05-06-2006 09:51 AM

Here's a basic PHP one I pulled out of my ass:

pictures.txt
Code:

image1.jpg|http://somelink.com/
imaagagads3.jpg|http://notherlinkg.com/
akadsfd.jpg|http://asdfasdf/

random_image.php
Code:

$file = file("pictures.txt");
list($img,$link) = each(explode("|",$filerand (0, (count($file)-1)));
echo "<a href=\"".$link."\"><img src=\"".$img."\"></a>";

* note, code not checked or validated to work

Antonio 05-06-2006 09:55 AM

http://www.tgpwiz.com/

see the free script and download it from there, it has thumbs/links option too (for building thumb TGP), the thing is it's been a long time since I used it so I can't really help you with install etc, good luck, hope it's what you're looking for

mikeyddddd 05-06-2006 09:59 AM

This PHP requires a separate text file to be created for 0-60 seconds:

Code:

$num = date("s");
$ads = "/path/to/text/file/$num.txt";

if (file_exists($ads)) {

$ads_in = file ("$ads");

for($i = 0; $i < sizeof($ads_in); $i++)
{ print("$ads_in[$i]\n"); }

} else {
print("Try Again - $num.txt - $ads");
}

date("s") can be changed to whatever time interval you want and will require a text file for each possible value.

Just set the text file up like you would normally code your HTML.

Lazonby 05-06-2006 10:21 AM

Quote:

Originally Posted by Franck

Borat says "I hev..... liquid explosion....... in my pants. IS NICE!"

He also says to have a look on google. You'll find loads of examples and you can swap and change them to find one which works best.

OG LennyT 05-06-2006 10:26 AM

Code:

<script language="Javascript">
<!--


var currentdate = 0;
var core = 0;

function initArray() {

this.length = initArray.arguments.length;
  for (var i = 0; i < this.length; i++) {
  this[i] = initArray.arguments[i];
  }
}

link = new initArray(
"http://www.yourlink1",
"http://www.yourlink2",
"http://www.yourlink3",
"http://www.yourlink4"
);

image = new initArray(
"http://imagelink.gif",
"http://imagelink.gif",
"http://imagelink.gif",
"http://imagelink.gif"
);

text = new initArray(
"textforlink!",
"text!",
"texxt!",
"rollovertext!"
);

var currentdate = new Date();
var core = currentdate.getSeconds() % image.length;
var ranlink  = link[core];
var ranimage = image[core];
var rantext  = text[core];

document.write('<a href=\"' +ranlink+ '\" target=\"_blank\"><img src=\"'+ranimage+'\" border="0" alt=\"'+rantext+'\"></a>');

//-->
</SCRIPT>

I use this for banner rotation, works well.


All times are GMT -7. The time now is 01:09 PM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123