Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Post New Thread Reply

Register GFY Rules Calendar
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed.

 
Thread Tools
Old 09-13-2006, 09:45 AM   #1
PantieZ
Confirmed User
 
PantieZ's Avatar
 
Join Date: Jan 2001
Location: Panty Land
Posts: 1,441
php gurus ... plz help $$

i build my galleries with this include :

<?php include("../temp.php"); ?>

how to code it that temp.php is random. i mean how to code it to let the include be a random .. like temp1.php , temp2.php ... etc ...

i am shure for a guru this is a joke ... if you help me i will send you a few epass bucks.


ICQ 132818937
PantieZ is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-13-2006, 09:47 AM   #2
Boobs
Confirmed User
 
Join Date: Aug 2006
Posts: 7,875
bump for u
Boobs is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-13-2006, 09:48 AM   #3
munki
Do Fun Shit.
 
munki's Avatar
 
Industry Role:
Join Date: Dec 2004
Location: OC
Posts: 13,393
http://us3.php.net/manual/en/function.rand.php
__________________

I have the simplest tastes. I am always satisfied with the best.” -Oscar Wilde
munki is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-13-2006, 09:50 AM   #4
darksoul
Confirmed User
 
darksoul's Avatar
 
Join Date: Apr 2002
Location: /root/
Posts: 4,997
Code:
$x = rand(1,20);
include("../temp$x.php");
__________________
1337 5y54|)m1n: 157717888
BM-2cUBw4B2fgiYAfjkE7JvWaJMiUXD96n9tN
Cambooth
darksoul is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-13-2006, 09:54 AM   #5
polle54
Confirmed User
 
Join Date: Jul 2004
Location: The Beach
Posts: 4,626
Quote:
Originally Posted by darksoul
Code:
$x = rand(1,20);
include("../temp$x.php");

thats a fine solution for your problem.
__________________
ICQ# 143561781
polle54 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-13-2006, 09:54 AM   #6
A-Bomb
Confirmed User
 
Industry Role:
Join Date: Dec 2004
Location: 1 of 3 holes
Posts: 680
Quote:
Originally Posted by darksoul
Code:
$x = rand(1,20);
include("../temp$x.php");
yup. That's the ticket.
A-Bomb is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-13-2006, 09:59 AM   #7
PantieZ
Confirmed User
 
PantieZ's Avatar
 
Join Date: Jan 2001
Location: Panty Land
Posts: 1,441
thx a lot
PantieZ is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-13-2006, 10:01 AM   #8
GrouchyAdmin
Now choke yourself!
 
GrouchyAdmin's Avatar
 
Industry Role:
Join Date: Apr 2006
Posts: 12,085
Efficient. I like that. I'd pad it just so filenames would match (banner001.php), etc, but that's just my pedantic design.

Code:
$x = printf(%02d, rand(1,20));
Sorry for the semi-hijack:

darksoul: Got a second for a question or two? I'm rather new to supporting AT3, and for some reason, in.cgi seems to semi-randomly zombie on a new install.

This site is not doing anything horribly exotic, either - it's using stock SSI. It eventually clears up, but it bothers me that I can get a quick burst of traffic and have 20 zombies.

This machine is also production, so I can't just drop gdb on it and try to figure what the @#$@! is going on.
__________________
GrouchyAdmin is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-13-2006, 10:27 AM   #9
vantage
Confirmed User
 
Join Date: Jun 2005
Location: BERLIN :: GERMANY
Posts: 214
I this thats saver!
PHP Code:

$files 
= array("../file1.inc","../file2.inc","../file3.inc");
include(
$files[rand(0,count($files))]); 
__________________
vantage is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Post New Thread Reply
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >

Bookmarks



Advertising inquiries - marketing at gfy dot com

Contact Admin - Advertise - GFY Rules - Top

©2000-, AI Media Network Inc



Powered by vBulletin
Copyright © 2000- Jelsoft Enterprises Limited.