Reputation:
how would I go about making a marquee in html? could I define everything i.e. speed, looping, text color, background color, direction, etc. With just html or should I need to know another language to define those aspects? Also could I implement an image in the marquee?
Upvotes: 0
Views: 3061
Reputation: 78
I recently implemented a marquee in HTML using Cycle 2 Jquery plugin : http://jquery.malsup.com/cycle2/demo/non-image.php
<div class="cycle-slideshow" data-cycle-fx="scrollHorz" data-cycle-speed="9000" data-cycle-timeout="1" data-cycle-easing="linear" data-cycle-pause-on-hover="true" data-cycle-slides="> div" >
<div> Text 1 </div>
<div> Text 2 </div>
</div>
Upvotes: 0
Reputation:
You can change the speed, direction and looping in the html but to edit background color you will need to use CSS. To style the text color, you do not need to style the <marquee> but you need to style the elements INSIDE the tag.
Upvotes: 0
Reputation: 4097
Something like this:
<MARQUEE id=Marquee2 title=""
style="BORDER-RIGHT: 1px; BORDER-TOP: 1px; PADDING-LEFT: 3px; Z-INDEX: 2; OVERFLOW: hidden; BORDER-LEFT: 1px; WIDTH: 5.197in; TEXT-INDENT: 0px; BORDER-BOTTOM: 1px; HEIGHT: 0.156in"
trueSpeed scrollDelay=150 MsoTextAlign="General">My Text Goes Here</MARQUEE>
Upvotes: 0
Reputation: 93565
You can do images in the marquee tag:
http://jdstiles.com/java/scrollers/scrollingimage.html
But it's not a good tag to use. Go for one of the many javascript libraries that do this, such as this Cross Browser Marquee that allows you to set all the parameters you like.
-Adam
Upvotes: 1
Reputation: 70001
@Paolo is correct, you also might wanna look into tools to do similar things but have much more functionality. jScroller for example.
Upvotes: 1
Reputation: 488464
You don't want to use that tag. Really. It is evil.
For alternatives, check out:
Upvotes: 7