Random link coding

Started on the old forum in January 2010 · view the original in the archive · old links redirect here

12 replies · 1,099 views · started 16 years ago · 1 min read

6 participants
wap-lord Junior · 31 posts #1

anyone have these coding randomlink.php or randomlink.txt

brand Senior · 391 posts #2

wap-lord wrote: anyone have these coding randomlink.php or randomlink.txt

this is what i use for my adverts

$quotes[] = "LINK GOES HERE";
$quotes[] = "LINK GOES HERE";
$quotes[] = "LINK GOES HERE";
$quotes[] = "LINK GOES HERE";
$quotes[] = "LINK GOES HERE";
$quotes[] = "LINK GOES HERE";
$quotes[] = "LINK GOES HERE";
$quotes[] = "LINK GOES HERE";
$quotes[] = "LINK GOES HERE";
$quotes[] = "LINK GOES HERE";
$quotes[] = "LINK GOES HERE";
$quotes[] = "LINK GOES HERE";
$quotes[] = "LINK GOES HERE";
srand ((double) microtime() * 1000000);  
$randomquote = rand(0,count($quotes)-1);  

echo " ".$quotes[$randomquote]."<br/></p>";

HELP THEM WHO HELPS YOU

External image (may be gone)

i only work on wapdesire v_2 coding only

wap-lord Junior · 31 posts #3

can u create a txt file and upload it maybe more people will need it

GiLL Senior · 356 posts #4

ok make a randomlink.php

put this in it

<?php $urls = array("http://site.com" ,"http://site1.com","http://site2.com"); //set the text links $text = array("java Games " ,"Downloads" ,"New Downloads","chat and downloads Free "); srand(time()); //set the number in (rand()%3); for however many links there are $random = (rand()%3); echo ("<a href = \"$urls[$random]\">$text[$random]</a> "); ?>

and include this file at any page you can add/remove more links and txt

left wap stuff

DiL Developer · 142 posts #7

wap-lord wrote: the $test not showing

Friend, i have this script . Just look here.

step 1.

creat a *.txt file with name msg.txt or any other name's which you want

Now just copy and past this code in your msg.txt file

::<a href="http://HeArT.wen9.com">HeArT.wen9.com</a>
::<a href="http://FileWap.co.cc">FileWap - Shere ur file</a>
::<a href="http://Findz.co.cc">Findz - Toplist</a>
::<a href="http://CodingForum.freehostia.com">Coding Forum!</a>
::<a href="http://sexindia.wen9.com">Free Hot Video!</a>
::<a href="http://Im4ChaT.co.cc">Chat site</a>

step 2.

after this just put this code where you want to show yor rendom link

$xfile = @file("msg.txt");
$random_num = rand (0,count($xfile)-1);
$udata = explode("::",$xfile[$random_num]);
echo $udata[1];

Now enjoy this script

GiLL Senior · 356 posts #8

what is not showing ? explain your problem and would be nice post your link where are you facing that issue

left wap stuff

wap-lord Junior · 31 posts #10

Thankx dil ur code actually works.

sklbd Junior · 47 posts #11

a simple code for lavair or same sites

core.php

function random_links() { $sec = date(s);

if($sec <2) { echo "<a href="http://site url ">link name </a> "; } else if($sec <5) {

echo "<a href="http://site url ">link name </a> "; }

else if($sec <8) {

echo "<a href="http://site url ">link name </a> ";

}

else if($sec <11) {

echo "<a href="http://site url ">link name </a> ";

}

else if($sec <13) {

echo "<a href="http://site url ">link name </a> ";

}

u can add more and more link by changing $sec<.....

use random_links() to show random links on any page .......

ShaK!L AhammeD

Sklifbd.CoM +88-01730039272

Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close