Add Scrolling message to the site status bar

wizeman

Banned
Messages
256
Reaction score
0
Points
0
Place this script up above te HTML code..

___________________________________________________
<script language="JavaScript" type="text/javascript">
<!--
//Thank you using this script.

// You may edit the message below.

var startMsg = "Welcome to www.and1balla.s5.com";

var str = "";
var msg = "";
var leftMsg = "";


function setMessage()
{
if (msg == "")
{
str = " ";
msg = startMsg;
leftMsg = "";
}

if (str.length == 1)
{
while (msg.substring(0, 1) == " ")
{
leftMsg = leftMsg + str;
str = msg.substring(0, 1);
msg = msg.substring(1, msg.length);
}

leftMsg = leftMsg + str;
str = msg.substring(0, 1);
msg = msg.substring(1, msg.length);

for (var ii = 0; ii < 120; ii++)
{
str = " " + str;
}
}
else
str = str.substring(10, str.length);

window.status = leftMsg + str;
// This editable value (1000 = 9 second)
// corresponds to the speed of the shooting
// message.
timeout = window.setTimeout('setMessage()',100);

}
// -->


<!--Update the BODY tag for the timer function.-->

<!-- You may edit the BODY color. -->
<BODY bgcolor="#FFFFFF" onload="timeout = window.setTimeout('setMessage()',500);">
 

stuffradio

New Member
Messages
38
Reaction score
0
Points
0
One question? Why would you do all that work when there is a way simpler way to do this? All you have to do is get your table, you can make it in photoshop or something, then inside the table put the following code, I'll do an EXAMPLE table, this table doesn't look fancy at all so don't expect much from it.
HTML:
<table width=200 height=50 cellpadding=0 cellspacing=0 bordercolor=black border=1>
<tr><td><marquee>This is what would show up and it would be scrolling text like what was shown in the above post!</marquee></td></tr></table>
 

vbchris

New Member
Messages
180
Reaction score
0
Points
0
stuffradio said:
One question? Why would you do all that work when there is a way simpler way to do this? All you have to do is get your table, you can make it in photoshop or something, then inside the table put the following code, I'll do an EXAMPLE table, this table doesn't look fancy at all so don't expect much from it.
HTML:
<table width=200 height=50 cellpadding=0 cellspacing=0 bordercolor=black border=1>
<tr><td><marquee>This is what would show up and it would be scrolling text like what was shown in the above post!</marquee></td></tr></table>


Because the script he's shown scrolls the text in the status bar, you can't do this with a normal marquee.
 

2dee

New Member
Messages
30
Reaction score
0
Points
0
Can you show example?
and btw to put this code in the body or in th head?
 

Vietkid58

Member
Messages
450
Reaction score
0
Points
16
hey, dipeshsilwal1, that post was off topic. anyways,

where do we put this code? in the head or wat? how do we implement if our site is in php? and where do we put the scrolling message?
 

r0gUe

New Member
Messages
84
Reaction score
0
Points
0
codes always go in body

good job with the code dont see any errors ^^
 

wizeman

Banned
Messages
256
Reaction score
0
Points
0
thanks everybody just trying to help out, if u need a tutorial on some other webdesign ask me i might be able to do it
 

Articz

New Member
Messages
864
Reaction score
0
Points
0
i used to have a scroling status bar thingy on my old site but it really started to bug me so i removed it thx for this tho :)
 
N

Nathan

Guest
If any site has this I will not trust the site and instantly exit the entire browser window. This script will cause less and less people to visit your site because you're masking links in the status bar. Sorry, but it's true.
 

dsfreak

New Member
Messages
1,338
Reaction score
0
Points
0
Still, there is an easier way. Put this code into the body tag

Code:
onload="window.status='Your text here!';return true


so, you should have this as a body tag now:

<body onload="windiow.status'Your Text here!';return true">


Note, this does not scroll, but it saves lots of space.
 

stylez

New Member
Messages
108
Reaction score
0
Points
0
stuffradio said:
One question? Why would you do all that work when there is a way simpler way to do this? All you have to do is get your table, you can make it in photoshop or something, then inside the table put the following code, I'll do an EXAMPLE table, this table doesn't look fancy at all so don't expect much from it.
HTML:
<table width=200 height=50 cellpadding=0 cellspacing=0 bordercolor=black border=1>
<tr><td><marquee>This is what would show up and it would be scrolling text like what was shown in the above post!</marquee></td></tr></table>

dude learn html, javascript, php before you start saying theres some way easier.

Anyways, nice tut dude.
 
Top