On Mar 5, 6:53 pm, Tobie Langel <[email protected]> wrote:
> Rob,
>
> Please have a look at the DOM specs.

I have, the issue is how it's implemented.  When the specs are written
without ambiguity and all browsers follow them, it might be reasonable
to use them as the sole criterion for doing something.  But life’s not
like that.  :-(

> The only area where you should not be using writeAttribute is:
>
> - When you want to store anything but a string (use the new storage
> API or expandos directly).
> - For setting or getting the value attribute of Form elements (use
> FormElement#(get|set)Value instead).

writeAttribute does not fix cross browser differences in the
implementation of setAttribute.

My reason for recommending using the dot property is that it works
reliably, is precise, does not have the idiosyncrasies of setAttribute
and, most of all, directly sets the property versus making at least 3
function calls to do (more or less) the same thing.

Feel free to recommend otherwise but I'd like to see some reasons why.


--
Rob
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to