Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

JavaScript Forum


You are currently viewing our JavaScript Forum as a guest. Please register to participate.
Login



Reply
Old 08-05-2005, 01:22 PM Rendom
Junior Talker

Posts: 2
Trades: 0
Hi i am doing some web pages and i was wondering if the is a way to display a different URL ever time the page is loaded using JavaScript or something

Thanks inadvanced

Jon
http://www.shouldhost.com
wheelerjuk is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 08-09-2005, 12:29 AM
amaranth's Avatar
Average Talker

Posts: 16
Trades: 0
HTML Code:
<SCRIPT language="JavaScript"><!--
links = new Array("url1","url2");
num = Math.ceil(links.length*Math.random());
document.write("<a href="+links[num]+">"+links[num]+"</a>");
//--><SCRIPT>
something like that. it might have a few syntax errors seeing as i typed it in just now, but the idea should do for your purposes... play around with it a bit... random = cool. jk

hope that helps ^^
__________________
~ I have seen life on this planet. That is why I am looking elsewhere. ~
amaranth is offline
Reply With Quote
View Public Profile Visit amaranth's homepage!
 
Reply     « Reply to Rendom
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.57982 seconds with 12 queries