Opened 15 years ago
Closed 15 years ago
#2646 closed bug (wontfix)
Exception in curCSS, when called with textnodes...
Reported by: | m_abs | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | 1.2.4 |
Component: | core | Version: | 1.2.3 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
I get an uncut exception from the curCSS function in firefox 2.0.0.13 under ubuntu 7.10.
Here is an example for code that gives that exception
$( "<b>TODO</b>: load this view<br /><input type='button' class='button' value='Close' onclick='alert( \"hallo\" );' />" ).appendTo( document.body ).show( );
I think it happens because the ": load this view" part from my string, becomes a textnode and apparently getComputedStyle doesn't work with that. I tried adding a try-catch around the line
var getComputedStyle = document.defaultView.getComputedStyle( elem, null );
in which I alerted the nodeName (was "#text") and the nodeValue (was ": load this view");
Maybe it would be a good idea to do some type checking.
Change History (1)
comment:1 Changed 15 years ago by
Milestone: | 1.2.3 → 1.2.4 |
---|---|
Resolution: | → wontfix |
Status: | new → closed |
Note: See
TracTickets for help on using
tickets.
In previous tickets, the reply was "The string passed to $() must be valid html, as in, wrapped with nodes"
So I think this is just invalid html.
I'll close for now, feel free to reopen if you have something to say.