View Full Version : Ajax XML Ticker

12-01-2006, 09:08 AM
1) Script Title: Ajax XML ticker

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex2/ajaxticker.htm

3) Describe problem: it's possible to for me to change the text color independently using html tag in the xml file? I tried it but it doesn't work, any suggestion?


12-01-2006, 12:34 PM
You should be able to insert inline CSS within the DIV(s) of the xml (txt) file, for example:

<div class="message" style="color: red">
<a href="http://www.javascriptkit.com" target="_new">JavaScript Kit</a><br />Comprehensive JavaScript tutorials and over 400+ free scripts!

You can't use external or global CSS inside the txt file, at least it won't work in IE due to rendering limitations in IE for files fetched via Ajax.

12-01-2006, 08:39 PM
thank, but it doesn't work. Do you know any ajax ticker that use external .html file instead of text file? thanks

12-01-2006, 10:37 PM
Ok, what will work for sure is to add to the CSS on your page definitions that target the .message class name:

<style type="text/css">

color: red;


The above would need to be added to your page displaying the ticker, and not the .txt file.

12-03-2006, 07:29 AM
thanks I got the color to work like I wanted. How do I vertical align the content display? For example I set the width and the height 300 by 200 pixels. But sometime the contents doesn't fill up 200 pixels in height, so if that the case I want the content to vertically align in the middle.