Hey Everybody! I'm having an issue that I really hope some nice person can give me a hand with. I am pretty new to Jquery and I'm really getting confused. I am currently working on this page:
http://www.empirepatiocovers.com/MetroBlack-Patio-Covers1.aspx (FYI: a lot of the page functionality does not work. We will be adding proper functionality eventually) There is a dynamically placed table that is pulling data from our XML sheet. This works beautifully. However the page needs to ultimately look like this: http://www.empirepatiocovers.com/MetroBlack-Patio-Covers.aspx See how the table background colors alternate? There is an "even" and an "odd" css class that is being applied to alternating tr's. I found a code that would apply that effect, in this article: http://blog.jquery.com/2006/10/18/zebra-table-showdown/, but that script is being applied to a table that is already on the page. Since ours is being build dynamically, this script is not working for us. Essentially what I need to do is create some kind of event handler or an event listener applies the alternating css classes once the table is finished loading. I understand the logic, but I don't know how make it work. I have been trying to figure out a solution for about 3-4 hours now but I have hit a wall. Even my friend, who is an experienced developer can't figure this one out. He said the only other solution he can think of is to determine what tables are going to be even and odd in my XML and get my .js file to call that. I don't have a problem doing this, but I know it will be very tedious considering my XML sheet contains all of our products, and I'd like to find an easier way to do it. This is the link to my .js file: http://www.empirepatiocovers.com/javascript/readXML.js I really appreciate everyone's help and look forward to some responses! Thanks so much! - Rachel