I am looking for a small free script that can randomizes urls in a .txt file, I found something that puts them in order and its a very useful little program.
randomizing urls in a text file.
Collapse
X
-
I think some kind of "Message of the Day" script is a direction to look in.Originally posted by FucksakesI am looking for a small free script that can randomizes urls in a .txt file, I found something that puts them in order and its a very useful little program.
Comment
-
-
$file = "urls.txt";
$fp = file($file);
srand((double)microtime()*1000000);
$urls = $fp[array_rand($fp)];
echo $urls;
will work much better
in the file you will have to put <a href="http://www.url.com">site</a><br>
or
$file = "urls.txt";
$fp = file($file);
srand((double)microtime()*1000000);
$urls = $fp[array_rand($fp)];
echo "<a href='$urls'>random site</a>\n";
hope that helpsComment
-
This has always worked fine for me.PHP Code:<? $links = file('textfile.txt'); srand ((float)microtime()*1000000); shuffle($links);?><?=$links[0];?>-uno
icq: 111-914
CrazyBabe.com - porn art
MojoHost - For all your hosting needs, present and future. Tell them I sent ya!Comment
-
let me explain the purpose I need this...
I will throw all my hosted galleries into 1 txt file and want to randomize the list and grab the top "50ish" links, list them on my site and delete them from the list, when I grab new hosted galleries I can just add them into the list and they will get added randomly.
is it possible to display the whole list of urls all mixed up, otherwise how will i know which ones been listed.
thanks for the help guys.Comment
-
-
sounsd like you need something custom
icq: 33375924 if you need a hand with itCustom Software Development, email: woj#at#wojfun#.#com to discuss details or skype: wojl2000 or gchat: wojfun or telegram: wojl2000
Affiliate program tools: Hosted Galleries Manager Banner Manager Video Manager
Wordpress Affiliate Plugin Pic/Movie of the Day Fansign Generator Zip ManagerComment


Comment