Jump to content

Help Please.


KyleKJune

Recommended Posts

how can i moddify this so that each link will only work once then when people goto site it will not use that one again and i also want to make it so that each computer can only visit my site one time.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN""http://www.w3.org/TR/html4/loose.dtd"><html><head><title>home</title><meta http-equiv="Content-type" content="text/html;charset=UTF-8"></head><body onload="goto()"><script type="text/javascript">var myArrayname = new Array();myArrayname[0] = "http://site url";myArrayname[1] = "http://site url";myArrayname[2] = "http://site url";myArrayname[3] = "http://site url";myArrayname[4] = "http://site url";myArrayname[5] = "http://site url";myArrayname[6] = "http://site url";myArrayname[7] = "http://site url";myArrayname[8] = "http://site url";myArrayname[9] = "http://site url";myArrayname[10] = "http://site url";myArrayname[11] = "http://site url";myArrayname[12] = "http://site url";myArrayname[13] = "http://site url";myArrayname[14] = "http://site url";myArrayname[15] = "http://site url";myArrayname[16] = "http://site url";myArrayname[17] = "http://site url";myArrayname[18] = "http://site url";myArrayname[19] = "http://site url";var myArrayRef = Math.ceil(Math.random() * myArrayname.length-1)document.getElementById('myAnchor').href=myArrayname[myArrayRef];function goto(){window.location = myArrayname[myArrayRef];}</script></body></html>

Link to comment
Share on other sites

You will have to use a server-side language to record the link the client used (probably through a gateway page), and then store that on the server (associated with, e.g., their IP address) so next time you print out the array of links you can only display the ones that the client hasn't picked.You can't do it client-side, though.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...