...

View Full Version : Text moving (looping text)



tiger101
03-03-2011, 01:44 AM
hey guys/gals

I'm looking for text to move to the side or up and down. Example (http://www.bnn.ca/) you see BBN (title on the site) below it is a black strip and below is a text loop. thats what i want to do. any sites you can recommend for that? anyone know how to do that or know any premade scripts for that in jquery or javascrip?

Fumigator
03-03-2011, 03:13 PM
Rather funny this functionality has been part of the basic HTML markup (<marquee> tag) and supported by browsers forever but apparently we can't do it without jQuery now :p

Google "jquery marquee" for lots of options.

tiger101
03-04-2011, 02:50 AM
Thanks!!!

bullant
03-04-2011, 03:07 AM
The marquee is now deprecated by the w3c.

tiger101
03-04-2011, 03:22 AM
:-(, so does that mean i cant use that? any other alternatives?

bullant
03-04-2011, 03:31 AM
You can use jQuery if you like but imo it is overkill for a simple task like scrolling text. You can do it with just a few lines of javascript by setting a setInterval to continually remove the 1st char off a string of text and push it to the end of the string. Or you can use css positioning to scroll a string across a div continually.

Just google something like "scrolling text javascript" and you'll get lots of examples.

tiger101
03-04-2011, 03:49 AM
how do i do it the css way? wouldnt it be faster doing it with css? better load time too no?



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum