X-Git-Url: http://git.asbjorn.biz/?a=blobdiff_plain;f=src%2Fselector%2Fselector.js;h=2cf0b640417b03fa2cb5535a3a6379afdb589fb9;hb=bdf05d890fe3a8cc085b2b4f13881ca043943e44;hp=4a90bb9fffb94d890ed01abc00b68d8211ea7112;hpb=28a80202b3d41ed69f529f91c2f5bc4e929d51fa;p=jquery.git diff --git a/src/selector/selector.js b/src/selector/selector.js index 4a90bb9..2cf0b64 100644 --- a/src/selector/selector.js +++ b/src/selector/selector.js @@ -63,7 +63,7 @@ jQuery.extend({ // Match: :even, :last-chlid, #id, .class new RegExp("^([:.#]*)(" + - ( jQuery.chars = jQuery.browser.safari && jQuery.browser.version < "3.0.0" ? "\\w" : "(?:[\\w\u0128-\uFFFF*_-]|\\\\.)" ) + "+)") + ( jQuery.chars = jQuery.browser.safari && parseInt(jQuery.browser.version) < 417 ? "(?:[\\w*_-]|\\\\.)" : "(?:[\\w\u0128-\uFFFF*_-]|\\\\.)" ) + "+)") ], multiFilter: function( expr, elems, not ) { @@ -99,7 +99,7 @@ jQuery.extend({ // Handle the common XPath // expression if ( !t.indexOf("//") ) { - context = context.documentElement; + //context = context.documentElement; t = t.substr(2,t.length); // And the / root expression @@ -142,7 +142,7 @@ jQuery.extend({ if ( t.indexOf(" ") == 0 ) continue; foundToken = true; } else { - re = /^((\/?\.\.)|([>\/+~]))\s*([a-z]*)/i; + re = /^((\/?\.\.)|([>\/+~]))\s*(\w*)/i; if ( (m = re.exec(t)) != null ) { r = [];