Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

message screen saver script.

Status
Not open for further replies.

andyfresh

Technical User
Oct 4, 2005
33
0
0
GB
Hi

Most people have seen a script similar to the following which displays a list of messages like a screensaver in a text area box however does anyone know how to display these messages in the same screensaver format but not inside one of the text boxes? I dont mind if its in between a <td></td> or if its in between a <h2></h2> however I would like it to be displayed without any visiable boundaries.

Can anyone help?


Code:
<html>
<head>
<script src="gets.js"></script>
</head>
<body onload="slidemessage()">

<table name="slideshow">
<tr>
<td></td>
</tr>
</table>


<form name="slideshow"><div align="center"><center>

<textarea rows="5" name="S11" cols="30" wrap="virtual"></textarea><br>
      <!--<input type="button" value="Take me there!" name="B1" onClick="window.location=messagelinks[curmsg]">--></p>
      </center></div>
    </form>


</body>
</html>

javascript code:

Code:
var curmsg=-1
var messages=new Array()
messages[0]="Check out CNN, one of the premier news site on the net, covering national international, sports, and wheather news!"
messages[1]="Visit Wired.com for the latest happenings in the technology sector."
messages[2]="Go to download.com to download the latest shareware and demo programs!"
//add more messages as desired

var messagelinks=new Array()
messagelinks[0]="[URL unfurl="true"]http://www.cnn.com"[/URL]
messagelinks[1]="[URL unfurl="true"]http://www.wired.com"[/URL]
messagelinks[2]="[URL unfurl="true"]http://www.download.com"[/URL]
//add more links as indicated by the number of messages 

function slidemessage(){
if (curmsg<messages.length-1)
curmsg++
else
curmsg=0
//document.getelementbyname("s").value=messages[curmsg]
document.slideshow[0].value=messages[curmsg]
setTimeout("slidemessage()",4500)
}
slidemessage()
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top