Skip to main content

Bug Tracker

Side navigation

#10776 closed bug (invalid)

Opened November 13, 2011 02:25PM UTC

Closed November 13, 2011 07:51PM UTC

Last modified April 23, 2012 11:16AM UTC

TypeError: 'undefined' is not a function (evaluating 'elem.nodeName.toLowerCase()') [jquery.js:1904]

Reported by: skyer.tw@gmail.com Owned by:
Priority: low Milestone: None
Component: data Version: 1.7
Keywords: Cc:
Blocked by: Blocking:
Description

jQuery version: 1.7

It raise this error when I try to call tab UI function - tabs.

If add the error handling here and the tabs function works well.

    // A method for determining if a DOM node can handle the data expando
    acceptData: function( elem ) {
        if ( elem.nodeName ) {
            var match = false;
            if (typeof elem.nodeName.toLowerCase != 'undefined')
                match = jQuery.noData[ elem.nodeName.toLowerCase() ];

            if ( match ) {
                return !(match === true || elem.getAttribute("classid") !== match);
            }
        }

        return true;
    }
Attachments (0)
Change History (2)

Changed November 13, 2011 07:51PM UTC by timmywil comment:1

component: unfileddata
priority: undecidedlow
resolution: → invalid
status: newclosed

Thanks for taking the time to contribute to the jQuery project! Please submit a bug report with a reduced test case from http://jsfiddle.net to the jQuery UI bug tracker for issues pertaining to jQuery UI. Requiring a check for the presence of toLowerCase() is an indication that something else is going on here.

Changed April 23, 2012 11:16AM UTC by anonymous comment:2

Hi thanks for this help.

I applied it and voila it worked