On Dec 15, 10:24 am, Diego Perini <diego.per...@gmail.com> wrote:
> it is not only "href" that has problems, seems all attributes having
> an URI string as value have to be read in the way you described.
> Some of them are: action, cite, codebase, data, href, longdesc,
> lowsrc, src, usemap.

The root cause, if I'm not mistaken, is that IE masks the element
attributes with properties when calling getAttribute(). So in the case
of url's, the full resolved url is stored in the property of the
object.

a.href==a.getAttribute('href')

If you want the true attribute value, this is when you have to specify
the second argument of 2.

> You will have to add ".cssText" in IE6/7 to read a slightly similar
> value:
>     javascript:alert(document.getElementsByTagName('textarea')
> [0].getAttribute('style').cssText);
> I don't think all these cases/differences are currently handled and I
> don't think they can be handled in a reasonable way.

This case seems to be handled with this code:

if ( !jQuery.support.style && notxml && name == "style" ) {
        if ( set ) {
                elem.style.cssText = "" + value;
        }
        return elem.style.cssText;
}

Matt Kruse

--

You received this message because you are subscribed to the Google Groups 
"jQuery Development" group.
To post to this group, send email to jquery-...@googlegroups.com.
To unsubscribe from this group, send email to 
jquery-dev+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/jquery-dev?hl=en.


Reply via email to