Opened 18 years ago
Closed 13 years ago
#615 closed defect (wontfix)
javascript failed in Internet Explorer
Reported by: | Owned by: | Noah Kantrowitz | |
---|---|---|---|
Priority: | normal | Component: | CtxtnavAddPlugin |
Severity: | critical | Keywords: | |
Cc: | Trac Release: | 0.10 |
Description
- Background
- http://msdn.microsoft.com/library/default.asp?url=/workshop/author/dhtml/reference/methods/getattribute.asp
- When retrieving the CLASS attribute using this method, set the sAttrName to be "className", which is the corresponding Dynamic HTML (DHTML) property.
- http://msdn.microsoft.com/library/default.asp?url=/workshop/author/dhtml/reference/methods/getattribute.asp
- Fix
- ctxtnavadd.js
if(li_node.getAttribute('class') == 'last' || li_node.getAttribute('className') == 'last') { return(li_node); }
- ctxtnavadd.js
Attachments (1)
Change History (6)
comment:1 Changed 18 years ago by
comment:2 Changed 18 years ago by
I think there is a neater way to do it,
In find_old_last() instead of the getAttribute call;
if( li_node.className == 'last' ) {
and in add_ctxtnav() instead of the setAttribute call;
new_li.className = 'last'; old_li.className = ;
These changes seem to work on both IE and Firefox for me, and don't require doing essentially the same thing twice :)
comment:3 Changed 18 years ago by
I've totally rework the JavaScript in the 0.11 version using jQuery. I don't really intend to backport these changes (as I am currently very lacking of free time), but if someone wants to make a backport patch, I'll take a look.
comment:4 Changed 17 years ago by
I fixed this IE problem before I come to this ticket. file attached attachment:ctxtnavadd.js
Can somebody help to check into 0.10 branch?
I can verify this fix solves the problem in IE. You also need to make a similar change to the code that resets the 'last' item's class.