Fix attribute types with spaces?

I was just curious, is there possibly any fix for attributes that are 
supposed to be values separated by spaces (like class)?  I see a lot of 
code like this:

document.getElementById('test').className += " newClass"

And I wonder why elements like these couldn't be treated/returned as an 
array or something like that.  I personally don't think that treating 
these values as strings is such a great idea, since getting rid of them 
requires the use of regular expressions in most languages.

-- 
http://www.mozilla.org/products/firefox/ - Get Firefox!
http://www.mozilla.org/products/thunderbird/ - Reclaim Your Inbox!

Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html

Received on Monday, 19 December 2005 01:49:14 UTC