Forum Moderators: open
The HTML-code is a nightmare to work with, but I'm not allowed to change it around. So the only thing I can do is to give the "real" tables a class. Actually, they already have that class.
Now, the people in charge wants to add JS-driven sorting of the tables for *all* the informational tables. Trouble is, such a script would potentially mess up the layout, which wouldn't be a good thing. However, if I could somehow get the class attribute, it'd be a piece of cake. Going around 5000+ pages adding the proper tables an id each is just not doable, especially since some of those pages have multiple tables.
But when I tried to find a way to do it, I got stumped. As far as I can see, the class element doesn't exist as far as the DOM is concerned. So is there anyone out there that knows how to access the class attribute through the DOM? ^^;
Remember that there is an overhead with this as the JS needs to build the array and cycle through it performing the for conditional arguements.
HTH