<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[559] wp-testdata/formatting/sizzle.js: Test for #19855 - Optimize wpautop by skipping the contents of &lt;pre&gt; blocks</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg > ul, #logmsg > ol { margin-left: 0; margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://unit-tests.trac.wordpress.org/changeset/559">559</a></dd>
<dt>Author</dt> <dd>kurtpayne</dd>
<dt>Date</dt> <dd>2012-03-02 00:19:45 +0000 (Fri, 02 Mar 2012)</dd>
</dl>

<h3>Log Message</h3>
<pre>Test for <a href="http://unit-tests.trac.wordpress.org/ticket/19855">#19855</a> - Optimize wpautop by skipping the contents of &lt;pre&gt; blocks</pre>

<h3>Added Paths</h3>
<ul>
<li><a href="#wptestdataformattingsizzlejs">wp-testdata/formatting/sizzle.js</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="wptestdataformattingsizzlejs"></a>
<div class="addfile"><h4>Added: wp-testdata/formatting/sizzle.js (0 => 559)</h4>
<pre class="diff"><span>
<span class="info">--- wp-testdata/formatting/sizzle.js                                (rev 0)
+++ wp-testdata/formatting/sizzle.js        2012-03-02 00:19:45 UTC (rev 559)
</span><span class="lines">@@ -0,0 +1,1445 @@
</span><ins>+/*!
+ * Sizzle CSS Selector Engine
+ *  Copyright 2011, The Dojo Foundation
+ *  Released under the MIT, BSD, and GPL Licenses.
+ *  More information: http://sizzlejs.com/
+ */
+(function(){
+
+var chunker = /((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['&quot;][^'&quot;]*['&quot;]|[^\[\]'&quot;]+)+\]|\\.|[^ &gt;+~,(\[\\]+)+|[&gt;+~])(\s*,\s*)?((?:.|\r|\n)*)/g,
+        expando = &quot;sizcache&quot; + (Math.random() + '').replace('.', ''),
+        done = 0,
+        toString = Object.prototype.toString,
+        hasDuplicate = false,
+        baseHasDuplicate = true,
+        rBackslash = /\\/g,
+        rReturn = /\r\n/g,
+        rNonWord = /\W/;
+
+// Here we check if the JavaScript engine is using some sort of
+// optimization where it does not always call our comparision
+// function. If that is the case, discard the hasDuplicate value.
+//   Thus far that includes Google Chrome.
+[0, 0].sort(function() {
+        baseHasDuplicate = false;
+        return 0;
+});
+
+var Sizzle = function( selector, context, results, seed ) {
+        results = results || [];
+        context = context || document;
+
+        var origContext = context;
+
+        if ( context.nodeType !== 1 &amp;&amp; context.nodeType !== 9 ) {
+                return [];
+        }
+
+        if ( !selector || typeof selector !== &quot;string&quot; ) {
+                return results;
+        }
+
+        var m, set, checkSet, extra, ret, cur, pop, i,
+                prune = true,
+                contextXML = Sizzle.isXML( context ),
+                parts = [],
+                soFar = selector;
+
+        // Reset the position of the chunker regexp (start from head)
+        do {
+                chunker.exec( &quot;&quot; );
+                m = chunker.exec( soFar );
+
+                if ( m ) {
+                        soFar = m[3];
+
+                        parts.push( m[1] );
+
+                        if ( m[2] ) {
+                                extra = m[3];
+                                break;
+                        }
+                }
+        } while ( m );
+
+        if ( parts.length &gt; 1 &amp;&amp; origPOS.exec( selector ) ) {
+
+                if ( parts.length === 2 &amp;&amp; Expr.relative[ parts[0] ] ) {
+                        set = posProcess( parts[0] + parts[1], context, seed );
+
+                } else {
+                        set = Expr.relative[ parts[0] ] ?
+                                [ context ] :
+                                Sizzle( parts.shift(), context );
+
+                        while ( parts.length ) {
+                                selector = parts.shift();
+
+                                if ( Expr.relative[ selector ] ) {
+                                        selector += parts.shift();
+                                }
+
+                                set = posProcess( selector, set, seed );
+                        }
+                }
+
+        } else {
+                // Take a shortcut and set the context if the root selector is an ID
+                // (but not if it'll be faster if the inner selector is an ID)
+                if ( !seed &amp;&amp; parts.length &gt; 1 &amp;&amp; context.nodeType === 9 &amp;&amp; !contextXML &amp;&amp;
+                                Expr.match.ID.test(parts[0]) &amp;&amp; !Expr.match.ID.test(parts[parts.length - 1]) ) {
+
+                        ret = Sizzle.find( parts.shift(), context, contextXML );
+                        context = ret.expr ?
+                                Sizzle.filter( ret.expr, ret.set )[0] :
+                                ret.set[0];
+                }
+
+                if ( context ) {
+                        ret = seed ?
+                                { expr: parts.pop(), set: makeArray(seed) } :
+                                Sizzle.find( parts.pop(), parts.length === 1 &amp;&amp; (parts[0] === &quot;~&quot; || parts[0] === &quot;+&quot;) &amp;&amp; context.parentNode ? context.parentNode : context, contextXML );
+
+                        set = ret.expr ?
+                                Sizzle.filter( ret.expr, ret.set ) :
+                                ret.set;
+
+                        if ( parts.length &gt; 0 ) {
+                                checkSet = makeArray( set );
+
+                        } else {
+                                prune = false;
+                        }
+
+                        while ( parts.length ) {
+                                cur = parts.pop();
+                                pop = cur;
+
+                                if ( !Expr.relative[ cur ] ) {
+                                        cur = &quot;&quot;;
+                                } else {
+                                        pop = parts.pop();
+                                }
+
+                                if ( pop == null ) {
+                                        pop = context;
+                                }
+
+                                Expr.relative[ cur ]( checkSet, pop, contextXML );
+                        }
+
+                } else {
+                        checkSet = parts = [];
+                }
+        }
+
+        if ( !checkSet ) {
+                checkSet = set;
+        }
+
+        if ( !checkSet ) {
+                Sizzle.error( cur || selector );
+        }
+
+        if ( toString.call(checkSet) === &quot;[object Array]&quot; ) {
+                if ( !prune ) {
+                        results.push.apply( results, checkSet );
+
+                } else if ( context &amp;&amp; context.nodeType === 1 ) {
+                        for ( i = 0; checkSet[i] != null; i++ ) {
+                                if ( checkSet[i] &amp;&amp; (checkSet[i] === true || checkSet[i].nodeType === 1 &amp;&amp; Sizzle.contains(context, checkSet[i])) ) {
+                                        results.push( set[i] );
+                                }
+                        }
+
+                } else {
+                        for ( i = 0; checkSet[i] != null; i++ ) {
+                                if ( checkSet[i] &amp;&amp; checkSet[i].nodeType === 1 ) {
+                                        results.push( set[i] );
+                                }
+                        }
+                }
+
+        } else {
+                makeArray( checkSet, results );
+        }
+
+        if ( extra ) {
+                Sizzle( extra, origContext, results, seed );
+                Sizzle.uniqueSort( results );
+        }
+
+        return results;
+};
+
+Sizzle.uniqueSort = function( results ) {
+        if ( sortOrder ) {
+                hasDuplicate = baseHasDuplicate;
+                results.sort( sortOrder );
+
+                if ( hasDuplicate ) {
+                        for ( var i = 1; i &lt; results.length; i++ ) {
+                                if ( results[i] === results[ i - 1 ] ) {
+                                        results.splice( i--, 1 );
+                                }
+                        }
+                }
+        }
+
+        return results;
+};
+
+Sizzle.matches = function( expr, set ) {
+        return Sizzle( expr, null, null, set );
+};
+
+Sizzle.matchesSelector = function( node, expr ) {
+        return Sizzle( expr, null, null, [node] ).length &gt; 0;
+};
+
+Sizzle.find = function( expr, context, isXML ) {
+        var set, i, len, match, type, left;
+
+        if ( !expr ) {
+                return [];
+        }
+
+        for ( i = 0, len = Expr.order.length; i &lt; len; i++ ) {
+                type = Expr.order[i];
+
+                if ( (match = Expr.leftMatch[ type ].exec( expr )) ) {
+                        left = match[1];
+                        match.splice( 1, 1 );
+
+                        if ( left.substr( left.length - 1 ) !== &quot;\\&quot; ) {
+                                match[1] = (match[1] || &quot;&quot;).replace( rBackslash, &quot;&quot; );
+                                set = Expr.find[ type ]( match, context, isXML );
+
+                                if ( set != null ) {
+                                        expr = expr.replace( Expr.match[ type ], &quot;&quot; );
+                                        break;
+                                }
+                        }
+                }
+        }
+
+        if ( !set ) {
+                set = typeof context.getElementsByTagName !== &quot;undefined&quot; ?
+                        context.getElementsByTagName( &quot;*&quot; ) :
+                        [];
+        }
+
+        return { set: set, expr: expr };
+};
+
+Sizzle.filter = function( expr, set, inplace, not ) {
+        var match, anyFound,
+                type, found, item, filter, left,
+                i, pass,
+                old = expr,
+                result = [],
+                curLoop = set,
+                isXMLFilter = set &amp;&amp; set[0] &amp;&amp; Sizzle.isXML( set[0] );
+
+        while ( expr &amp;&amp; set.length ) {
+                for ( type in Expr.filter ) {
+                        if ( (match = Expr.leftMatch[ type ].exec( expr )) != null &amp;&amp; match[2] ) {
+                                filter = Expr.filter[ type ];
+                                left = match[1];
+
+                                anyFound = false;
+
+                                match.splice(1,1);
+
+                                if ( left.substr( left.length - 1 ) === &quot;\\&quot; ) {
+                                        continue;
+                                }
+
+                                if ( curLoop === result ) {
+                                        result = [];
+                                }
+
+                                if ( Expr.preFilter[ type ] ) {
+                                        match = Expr.preFilter[ type ]( match, curLoop, inplace, result, not, isXMLFilter );
+
+                                        if ( !match ) {
+                                                anyFound = found = true;
+
+                                        } else if ( match === true ) {
+                                                continue;
+                                        }
+                                }
+
+                                if ( match ) {
+                                        for ( i = 0; (item = curLoop[i]) != null; i++ ) {
+                                                if ( item ) {
+                                                        found = filter( item, match, i, curLoop );
+                                                        pass = not ^ found;
+
+                                                        if ( inplace &amp;&amp; found != null ) {
+                                                                if ( pass ) {
+                                                                        anyFound = true;
+
+                                                                } else {
+                                                                        curLoop[i] = false;
+                                                                }
+
+                                                        } else if ( pass ) {
+                                                                result.push( item );
+                                                                anyFound = true;
+                                                        }
+                                                }
+                                        }
+                                }
+
+                                if ( found !== undefined ) {
+                                        if ( !inplace ) {
+                                                curLoop = result;
+                                        }
+
+                                        expr = expr.replace( Expr.match[ type ], &quot;&quot; );
+
+                                        if ( !anyFound ) {
+                                                return [];
+                                        }
+
+                                        break;
+                                }
+                        }
+                }
+
+                // Improper expression
+                if ( expr === old ) {
+                        if ( anyFound == null ) {
+                                Sizzle.error( expr );
+
+                        } else {
+                                break;
+                        }
+                }
+
+                old = expr;
+        }
+
+        return curLoop;
+};
+
+Sizzle.error = function( msg ) {
+        throw new Error( &quot;Syntax error, unrecognized expression: &quot; + msg );
+};
+
+/**
+ * Utility function for retreiving the text value of an array of DOM nodes
+ * @param {Array|Element} elem
+ */
+var getText = Sizzle.getText = function( elem ) {
+    var i, node,
+                nodeType = elem.nodeType,
+                ret = &quot;&quot;;
+
+        if ( nodeType ) {
+                if ( nodeType === 1 || nodeType === 9 || nodeType === 11 ) {
+                        // Use textContent || innerText for elements
+                        if ( typeof elem.textContent === 'string' ) {
+                                return elem.textContent;
+                        } else if ( typeof elem.innerText === 'string' ) {
+                                // Replace IE's carriage returns
+                                return elem.innerText.replace( rReturn, '' );
+                        } else {
+                                // Traverse it's children
+                                for ( elem = elem.firstChild; elem; elem = elem.nextSibling) {
+                                        ret += getText( elem );
+                                }
+                        }
+                } else if ( nodeType === 3 || nodeType === 4 ) {
+                        return elem.nodeValue;
+                }
+        } else {
+
+                // If no nodeType, this is expected to be an array
+                for ( i = 0; (node = elem[i]); i++ ) {
+                        // Do not traverse comment nodes
+                        if ( node.nodeType !== 8 ) {
+                                ret += getText( node );
+                        }
+                }
+        }
+        return ret;
+};
+
+var Expr = Sizzle.selectors = {
+        order: [ &quot;ID&quot;, &quot;NAME&quot;, &quot;TAG&quot; ],
+
+        match: {
+                ID: /#((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,
+                CLASS: /\.((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,
+                NAME: /\[name=['&quot;]*((?:[\w\u00c0-\uFFFF\-]|\\.)+)['&quot;]*\]/,
+                ATTR: /\[\s*((?:[\w\u00c0-\uFFFF\-]|\\.)+)\s*(?:(\S?=)\s*(?:(['&quot;])(.*?)\3|(#?(?:[\w\u00c0-\uFFFF\-]|\\.)*)|)|)\s*\]/,
+                TAG: /^((?:[\w\u00c0-\uFFFF\*\-]|\\.)+)/,
+                CHILD: /:(only|nth|last|first)-child(?:\(\s*(even|odd|(?:[+\-]?\d+|(?:[+\-]?\d*)?n\s*(?:[+\-]\s*\d+)?))\s*\))?/,
+                POS: /:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^\-]|$)/,
+                PSEUDO: /:((?:[\w\u00c0-\uFFFF\-]|\\.)+)(?:\((['&quot;]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/
+        },
+
+        leftMatch: {},
+
+        attrMap: {
+                &quot;class&quot;: &quot;className&quot;,
+                &quot;for&quot;: &quot;htmlFor&quot;
+        },
+
+        attrHandle: {
+                href: function( elem ) {
+                        return elem.getAttribute( &quot;href&quot; );
+                },
+                type: function( elem ) {
+                        return elem.getAttribute( &quot;type&quot; );
+                }
+        },
+
+        relative: {
+                &quot;+&quot;: function(checkSet, part){
+                        var isPartStr = typeof part === &quot;string&quot;,
+                                isTag = isPartStr &amp;&amp; !rNonWord.test( part ),
+                                isPartStrNotTag = isPartStr &amp;&amp; !isTag;
+
+                        if ( isTag ) {
+                                part = part.toLowerCase();
+                        }
+
+                        for ( var i = 0, l = checkSet.length, elem; i &lt; l; i++ ) {
+                                if ( (elem = checkSet[i]) ) {
+                                        while ( (elem = elem.previousSibling) &amp;&amp; elem.nodeType !== 1 ) {}
+
+                                        checkSet[i] = isPartStrNotTag || elem &amp;&amp; elem.nodeName.toLowerCase() === part ?
+                                                elem || false :
+                                                elem === part;
+                                }
+                        }
+
+                        if ( isPartStrNotTag ) {
+                                Sizzle.filter( part, checkSet, true );
+                        }
+                },
+
+                &quot;&gt;&quot;: function( checkSet, part ) {
+                        var elem,
+                                isPartStr = typeof part === &quot;string&quot;,
+                                i = 0,
+                                l = checkSet.length;
+
+                        if ( isPartStr &amp;&amp; !rNonWord.test( part ) ) {
+                                part = part.toLowerCase();
+
+                                for ( ; i &lt; l; i++ ) {
+                                        elem = checkSet[i];
+
+                                        if ( elem ) {
+                                                var parent = elem.parentNode;
+                                                checkSet[i] = parent.nodeName.toLowerCase() === part ? parent : false;
+                                        }
+                                }
+
+                        } else {
+                                for ( ; i &lt; l; i++ ) {
+                                        elem = checkSet[i];
+
+                                        if ( elem ) {
+                                                checkSet[i] = isPartStr ?
+                                                        elem.parentNode :
+                                                        elem.parentNode === part;
+                                        }
+                                }
+
+                                if ( isPartStr ) {
+                                        Sizzle.filter( part, checkSet, true );
+                                }
+                        }
+                },
+
+                &quot;&quot;: function(checkSet, part, isXML){
+                        var nodeCheck,
+                                doneName = done++,
+                                checkFn = dirCheck;
+
+                        if ( typeof part === &quot;string&quot; &amp;&amp; !rNonWord.test( part ) ) {
+                                part = part.toLowerCase();
+                                nodeCheck = part;
+                                checkFn = dirNodeCheck;
+                        }
+
+                        checkFn( &quot;parentNode&quot;, part, doneName, checkSet, nodeCheck, isXML );
+                },
+
+                &quot;~&quot;: function( checkSet, part, isXML ) {
+                        var nodeCheck,
+                                doneName = done++,
+                                checkFn = dirCheck;
+
+                        if ( typeof part === &quot;string&quot; &amp;&amp; !rNonWord.test( part ) ) {
+                                part = part.toLowerCase();
+                                nodeCheck = part;
+                                checkFn = dirNodeCheck;
+                        }
+
+                        checkFn( &quot;previousSibling&quot;, part, doneName, checkSet, nodeCheck, isXML );
+                }
+        },
+
+        find: {
+                ID: function( match, context, isXML ) {
+                        if ( typeof context.getElementById !== &quot;undefined&quot; &amp;&amp; !isXML ) {
+                                var m = context.getElementById(match[1]);
+                                // Check parentNode to catch when Blackberry 4.6 returns
+                                // nodes that are no longer in the document #6963
+                                return m &amp;&amp; m.parentNode ? [m] : [];
+                        }
+                },
+
+                NAME: function( match, context ) {
+                        if ( typeof context.getElementsByName !== &quot;undefined&quot; ) {
+                                var ret = [],
+                                        results = context.getElementsByName( match[1] );
+
+                                for ( var i = 0, l = results.length; i &lt; l; i++ ) {
+                                        if ( results[i].getAttribute(&quot;name&quot;) === match[1] ) {
+                                                ret.push( results[i] );
+                                        }
+                                }
+
+                                return ret.length === 0 ? null : ret;
+                        }
+                },
+
+                TAG: function( match, context ) {
+                        if ( typeof context.getElementsByTagName !== &quot;undefined&quot; ) {
+                                return context.getElementsByTagName( match[1] );
+                        }
+                }
+        },
+        preFilter: {
+                CLASS: function( match, curLoop, inplace, result, not, isXML ) {
+                        match = &quot; &quot; + match[1].replace( rBackslash, &quot;&quot; ) + &quot; &quot;;
+
+                        if ( isXML ) {
+                                return match;
+                        }
+
+                        for ( var i = 0, elem; (elem = curLoop[i]) != null; i++ ) {
+                                if ( elem ) {
+                                        if ( not ^ (elem.className &amp;&amp; (&quot; &quot; + elem.className + &quot; &quot;).replace(/[\t\n\r]/g, &quot; &quot;).indexOf(match) &gt;= 0) ) {
+                                                if ( !inplace ) {
+                                                        result.push( elem );
+                                                }
+
+                                        } else if ( inplace ) {
+                                                curLoop[i] = false;
+                                        }
+                                }
+                        }
+
+                        return false;
+                },
+
+                ID: function( match ) {
+                        return match[1].replace( rBackslash, &quot;&quot; );
+                },
+
+                TAG: function( match, curLoop ) {
+                        return match[1].replace( rBackslash, &quot;&quot; ).toLowerCase();
+                },
+
+                CHILD: function( match ) {
+                        if ( match[1] === &quot;nth&quot; ) {
+                                if ( !match[2] ) {
+                                        Sizzle.error( match[0] );
+                                }
+
+                                match[2] = match[2].replace(/^\+|\s*/g, '');
+
+                                // parse equations like 'even', 'odd', '5', '2n', '3n+2', '4n-1', '-n+6'
+                                var test = /(-?)(\d*)(?:n([+\-]?\d*))?/.exec(
+                                        match[2] === &quot;even&quot; &amp;&amp; &quot;2n&quot; || match[2] === &quot;odd&quot; &amp;&amp; &quot;2n+1&quot; ||
+                                        !/\D/.test( match[2] ) &amp;&amp; &quot;0n+&quot; + match[2] || match[2]);
+
+                                // calculate the numbers (first)n+(last) including if they are negative
+                                match[2] = (test[1] + (test[2] || 1)) - 0;
+                                match[3] = test[3] - 0;
+                        }
+                        else if ( match[2] ) {
+                                Sizzle.error( match[0] );
+                        }
+
+                        // TODO: Move to normal caching system
+                        match[0] = done++;
+
+                        return match;
+                },
+
+                ATTR: function( match, curLoop, inplace, result, not, isXML ) {
+                        var name = match[1] = match[1].replace( rBackslash, &quot;&quot; );
+
+                        if ( !isXML &amp;&amp; Expr.attrMap[name] ) {
+                                match[1] = Expr.attrMap[name];
+                        }
+
+                        // Handle if an un-quoted value was used
+                        match[4] = ( match[4] || match[5] || &quot;&quot; ).replace( rBackslash, &quot;&quot; );
+
+                        if ( match[2] === &quot;~=&quot; ) {
+                                match[4] = &quot; &quot; + match[4] + &quot; &quot;;
+                        }
+
+                        return match;
+                },
+
+                PSEUDO: function( match, curLoop, inplace, result, not ) {
+                        if ( match[1] === &quot;not&quot; ) {
+                                // If we're dealing with a complex expression, or a simple one
+                                if ( ( chunker.exec(match[3]) || &quot;&quot; ).length &gt; 1 || /^\w/.test(match[3]) ) {
+                                        match[3] = Sizzle(match[3], null, null, curLoop);
+
+                                } else {
+                                        var ret = Sizzle.filter(match[3], curLoop, inplace, true ^ not);
+
+                                        if ( !inplace ) {
+                                                result.push.apply( result, ret );
+                                        }
+
+                                        return false;
+                                }
+
+                        } else if ( Expr.match.POS.test( match[0] ) || Expr.match.CHILD.test( match[0] ) ) {
+                                return true;
+                        }
+
+                        return match;
+                },
+
+                POS: function( match ) {
+                        match.unshift( true );
+
+                        return match;
+                }
+        },
+
+        filters: {
+                enabled: function( elem ) {
+                        return elem.disabled === false &amp;&amp; elem.type !== &quot;hidden&quot;;
+                },
+
+                disabled: function( elem ) {
+                        return elem.disabled === true;
+                },
+
+                checked: function( elem ) {
+                        return elem.checked === true;
+                },
+
+                selected: function( elem ) {
+                        // Accessing this property makes selected-by-default
+                        // options in Safari work properly
+                        if ( elem.parentNode ) {
+                                elem.parentNode.selectedIndex;
+                        }
+
+                        return elem.selected === true;
+                },
+
+                parent: function( elem ) {
+                        return !!elem.firstChild;
+                },
+
+                empty: function( elem ) {
+                        return !elem.firstChild;
+                },
+
+                has: function( elem, i, match ) {
+                        return !!Sizzle( match[3], elem ).length;
+                },
+
+                header: function( elem ) {
+                        return (/h\d/i).test( elem.nodeName );
+                },
+
+                text: function( elem ) {
+                        var attr = elem.getAttribute( &quot;type&quot; ), type = elem.type;
+                        // IE6 and 7 will map elem.type to 'text' for new HTML5 types (search, etc)
+                        // use getAttribute instead to test this case
+                        return elem.nodeName.toLowerCase() === &quot;input&quot; &amp;&amp; &quot;text&quot; === type &amp;&amp; ( attr === type || attr === null );
+                },
+
+                radio: function( elem ) {
+                        return elem.nodeName.toLowerCase() === &quot;input&quot; &amp;&amp; &quot;radio&quot; === elem.type;
+                },
+
+                checkbox: function( elem ) {
+                        return elem.nodeName.toLowerCase() === &quot;input&quot; &amp;&amp; &quot;checkbox&quot; === elem.type;
+                },
+
+                file: function( elem ) {
+                        return elem.nodeName.toLowerCase() === &quot;input&quot; &amp;&amp; &quot;file&quot; === elem.type;
+                },
+
+                password: function( elem ) {
+                        return elem.nodeName.toLowerCase() === &quot;input&quot; &amp;&amp; &quot;password&quot; === elem.type;
+                },
+
+                submit: function( elem ) {
+                        var name = elem.nodeName.toLowerCase();
+                        return (name === &quot;input&quot; || name === &quot;button&quot;) &amp;&amp; &quot;submit&quot; === elem.type;
+                },
+
+                image: function( elem ) {
+                        return elem.nodeName.toLowerCase() === &quot;input&quot; &amp;&amp; &quot;image&quot; === elem.type;
+                },
+
+                reset: function( elem ) {
+                        var name = elem.nodeName.toLowerCase();
+                        return (name === &quot;input&quot; || name === &quot;button&quot;) &amp;&amp; &quot;reset&quot; === elem.type;
+                },
+
+                button: function( elem ) {
+                        var name = elem.nodeName.toLowerCase();
+                        return name === &quot;input&quot; &amp;&amp; &quot;button&quot; === elem.type || name === &quot;button&quot;;
+                },
+
+                input: function( elem ) {
+                        return (/input|select|textarea|button/i).test( elem.nodeName );
+                },
+
+                focus: function( elem ) {
+                        return elem === elem.ownerDocument.activeElement;
+                }
+        },
+        setFilters: {
+                first: function( elem, i ) {
+                        return i === 0;
+                },
+
+                last: function( elem, i, match, array ) {
+                        return i === array.length - 1;
+                },
+
+                even: function( elem, i ) {
+                        return i % 2 === 0;
+                },
+
+                odd: function( elem, i ) {
+                        return i % 2 === 1;
+                },
+
+                lt: function( elem, i, match ) {
+                        return i &lt; match[3] - 0;
+                },
+
+                gt: function( elem, i, match ) {
+                        return i &gt; match[3] - 0;
+                },
+
+                nth: function( elem, i, match ) {
+                        return match[3] - 0 === i;
+                },
+
+                eq: function( elem, i, match ) {
+                        return match[3] - 0 === i;
+                }
+        },
+        filter: {
+                PSEUDO: function( elem, match, i, array ) {
+                        var name = match[1],
+                                filter = Expr.filters[ name ];
+
+                        if ( filter ) {
+                                return filter( elem, i, match, array );
+
+                        } else if ( name === &quot;contains&quot; ) {
+                                return (elem.textContent || elem.innerText || getText([ elem ]) || &quot;&quot;).indexOf(match[3]) &gt;= 0;
+
+                        } else if ( name === &quot;not&quot; ) {
+                                var not = match[3];
+
+                                for ( var j = 0, l = not.length; j &lt; l; j++ ) {
+                                        if ( not[j] === elem ) {
+                                                return false;
+                                        }
+                                }
+
+                                return true;
+
+                        } else {
+                                Sizzle.error( name );
+                        }
+                },
+
+                CHILD: function( elem, match ) {
+                        var first, last,
+                                doneName, parent, cache,
+                                count, diff,
+                                type = match[1],
+                                node = elem;
+
+                        switch ( type ) {
+                                case &quot;only&quot;:
+                                case &quot;first&quot;:
+                                        while ( (node = node.previousSibling) ) {
+                                                if ( node.nodeType === 1 ) {
+                                                        return false;
+                                                }
+                                        }
+
+                                        if ( type === &quot;first&quot; ) {
+                                                return true;
+                                        }
+
+                                        node = elem;
+
+                                        /* falls through */
+                                case &quot;last&quot;:
+                                        while ( (node = node.nextSibling) ) {
+                                                if ( node.nodeType === 1 ) {
+                                                        return false;
+                                                }
+                                        }
+
+                                        return true;
+
+                                case &quot;nth&quot;:
+                                        first = match[2];
+                                        last = match[3];
+
+                                        if ( first === 1 &amp;&amp; last === 0 ) {
+                                                return true;
+                                        }
+
+                                        doneName = match[0];
+                                        parent = elem.parentNode;
+
+                                        if ( parent &amp;&amp; (parent[ expando ] !== doneName || !elem.nodeIndex) ) {
+                                                count = 0;
+
+                                                for ( node = parent.firstChild; node; node = node.nextSibling ) {
+                                                        if ( node.nodeType === 1 ) {
+                                                                node.nodeIndex = ++count;
+                                                        }
+                                                }
+
+                                                parent[ expando ] = doneName;
+                                        }
+
+                                        diff = elem.nodeIndex - last;
+
+                                        if ( first === 0 ) {
+                                                return diff === 0;
+
+                                        } else {
+                                                return ( diff % first === 0 &amp;&amp; diff / first &gt;= 0 );
+                                        }
+                        }
+                },
+
+                ID: function( elem, match ) {
+                        return elem.nodeType === 1 &amp;&amp; elem.getAttribute(&quot;id&quot;) === match;
+                },
+
+                TAG: function( elem, match ) {
+                        return (match === &quot;*&quot; &amp;&amp; elem.nodeType === 1) || !!elem.nodeName &amp;&amp; elem.nodeName.toLowerCase() === match;
+                },
+
+                CLASS: function( elem, match ) {
+                        return (&quot; &quot; + (elem.className || elem.getAttribute(&quot;class&quot;)) + &quot; &quot;)
+                                .indexOf( match ) &gt; -1;
+                },
+
+                ATTR: function( elem, match ) {
+                        var name = match[1],
+                                result = Sizzle.attr ?
+                                        Sizzle.attr( elem, name ) :
+                                        Expr.attrHandle[ name ] ?
+                                        Expr.attrHandle[ name ]( elem ) :
+                                        elem[ name ] != null ?
+                                                elem[ name ] :
+                                                elem.getAttribute( name ),
+                                value = result + &quot;&quot;,
+                                type = match[2],
+                                check = match[4];
+
+                        return result == null ?
+                                type === &quot;!=&quot; :
+                                !type &amp;&amp; Sizzle.attr ?
+                                result != null :
+                                type === &quot;=&quot; ?
+                                value === check :
+                                type === &quot;*=&quot; ?
+                                value.indexOf(check) &gt;= 0 :
+                                type === &quot;~=&quot; ?
+                                (&quot; &quot; + value + &quot; &quot;).indexOf(check) &gt;= 0 :
+                                !check ?
+                                value &amp;&amp; result !== false :
+                                type === &quot;!=&quot; ?
+                                value !== check :
+                                type === &quot;^=&quot; ?
+                                value.indexOf(check) === 0 :
+                                type === &quot;$=&quot; ?
+                                value.substr(value.length - check.length) === check :
+                                type === &quot;|=&quot; ?
+                                value === check || value.substr(0, check.length + 1) === check + &quot;-&quot; :
+                                false;
+                },
+
+                POS: function( elem, match, i, array ) {
+                        var name = match[2],
+                                filter = Expr.setFilters[ name ];
+
+                        if ( filter ) {
+                                return filter( elem, i, match, array );
+                        }
+                }
+        }
+};
+
+var origPOS = Expr.match.POS,
+        fescape = function(all, num){
+                return &quot;\\&quot; + (num - 0 + 1);
+        };
+
+for ( var type in Expr.match ) {
+        Expr.match[ type ] = new RegExp( Expr.match[ type ].source + (/(?![^\[]*\])(?![^\(]*\))/.source) );
+        Expr.leftMatch[ type ] = new RegExp( /(^(?:.|\r|\n)*?)/.source + Expr.match[ type ].source.replace(/\\(\d+)/g, fescape) );
+}
+// Expose origPOS
+// &quot;global&quot; as in regardless of relation to brackets/parens
+Expr.match.globalPOS = origPOS;
+
+var makeArray = function( array, results ) {
+        array = Array.prototype.slice.call( array, 0 );
+
+        if ( results ) {
+                results.push.apply( results, array );
+                return results;
+        }
+
+        return array;
+};
+
+// Perform a simple check to determine if the browser is capable of
+// converting a NodeList to an array using builtin methods.
+// Also verifies that the returned array holds DOM nodes
+// (which is not the case in the Blackberry browser)
+try {
+        Array.prototype.slice.call( document.documentElement.childNodes, 0 )[0].nodeType;
+
+// Provide a fallback method if it does not work
+} catch( e ) {
+        makeArray = function( array, results ) {
+                var i = 0,
+                        ret = results || [];
+
+                if ( toString.call(array) === &quot;[object Array]&quot; ) {
+                        Array.prototype.push.apply( ret, array );
+
+                } else {
+                        if ( typeof array.length === &quot;number&quot; ) {
+                                for ( var l = array.length; i &lt; l; i++ ) {
+                                        ret.push( array[i] );
+                                }
+
+                        } else {
+                                for ( ; array[i]; i++ ) {
+                                        ret.push( array[i] );
+                                }
+                        }
+                }
+
+                return ret;
+        };
+}
+
+var sortOrder, siblingCheck;
+
+if ( document.documentElement.compareDocumentPosition ) {
+        sortOrder = function( a, b ) {
+                if ( a === b ) {
+                        hasDuplicate = true;
+                        return 0;
+                }
+
+                if ( !a.compareDocumentPosition || !b.compareDocumentPosition ) {
+                        return a.compareDocumentPosition ? -1 : 1;
+                }
+
+                return a.compareDocumentPosition(b) &amp; 4 ? -1 : 1;
+        };
+
+} else {
+        sortOrder = function( a, b ) {
+                // The nodes are identical, we can exit early
+                if ( a === b ) {
+                        hasDuplicate = true;
+                        return 0;
+
+                // Fallback to using sourceIndex (in IE) if it's available on both nodes
+                } else if ( a.sourceIndex &amp;&amp; b.sourceIndex ) {
+                        return a.sourceIndex - b.sourceIndex;
+                }
+
+                var al, bl,
+                        ap = [],
+                        bp = [],
+                        aup = a.parentNode,
+                        bup = b.parentNode,
+                        cur = aup;
+
+                // If the nodes are siblings (or identical) we can do a quick check
+                if ( aup === bup ) {
+                        return siblingCheck( a, b );
+
+                // If no parents were found then the nodes are disconnected
+                } else if ( !aup ) {
+                        return -1;
+
+                } else if ( !bup ) {
+                        return 1;
+                }
+
+                // Otherwise they're somewhere else in the tree so we need
+                // to build up a full list of the parentNodes for comparison
+                while ( cur ) {
+                        ap.unshift( cur );
+                        cur = cur.parentNode;
+                }
+
+                cur = bup;
+
+                while ( cur ) {
+                        bp.unshift( cur );
+                        cur = cur.parentNode;
+                }
+
+                al = ap.length;
+                bl = bp.length;
+
+                // Start walking down the tree looking for a discrepancy
+                for ( var i = 0; i &lt; al &amp;&amp; i &lt; bl; i++ ) {
+                        if ( ap[i] !== bp[i] ) {
+                                return siblingCheck( ap[i], bp[i] );
+                        }
+                }
+
+                // We ended someplace up the tree so do a sibling check
+                return i === al ?
+                        siblingCheck( a, bp[i], -1 ) :
+                        siblingCheck( ap[i], b, 1 );
+        };
+
+        siblingCheck = function( a, b, ret ) {
+                if ( a === b ) {
+                        return ret;
+                }
+
+                var cur = a.nextSibling;
+
+                while ( cur ) {
+                        if ( cur === b ) {
+                                return -1;
+                        }
+
+                        cur = cur.nextSibling;
+                }
+
+                return 1;
+        };
+}
+
+// Check to see if the browser returns elements by name when
+// querying by getElementById (and provide a workaround)
+(function(){
+        // We're going to inject a fake input element with a specified name
+        var form = document.createElement(&quot;div&quot;),
+                id = &quot;script&quot; + (new Date()).getTime(),
+                root = document.documentElement;
+
+        form.innerHTML = &quot;&lt;a name='&quot; + id + &quot;'/&gt;&quot;;
+
+        // Inject it into the root element, check its status, and remove it quickly
+        root.insertBefore( form, root.firstChild );
+
+        // The workaround has to do additional checks after a getElementById
+        // Which slows things down for other browsers (hence the branching)
+        if ( document.getElementById( id ) ) {
+                Expr.find.ID = function( match, context, isXML ) {
+                        if ( typeof context.getElementById !== &quot;undefined&quot; &amp;&amp; !isXML ) {
+                                var m = context.getElementById(match[1]);
+
+                                return m ?
+                                        m.id === match[1] || typeof m.getAttributeNode !== &quot;undefined&quot; &amp;&amp; m.getAttributeNode(&quot;id&quot;).nodeValue === match[1] ?
+                                                [m] :
+                                                undefined :
+                                        [];
+                        }
+                };
+
+                Expr.filter.ID = function( elem, match ) {
+                        var node = typeof elem.getAttributeNode !== &quot;undefined&quot; &amp;&amp; elem.getAttributeNode(&quot;id&quot;);
+
+                        return elem.nodeType === 1 &amp;&amp; node &amp;&amp; node.nodeValue === match;
+                };
+        }
+
+        root.removeChild( form );
+
+        // release memory in IE
+        root = form = null;
+})();
+
+(function(){
+        // Check to see if the browser returns only elements
+        // when doing getElementsByTagName(&quot;*&quot;)
+
+        // Create a fake element
+        var div = document.createElement(&quot;div&quot;);
+        div.appendChild( document.createComment(&quot;&quot;) );
+
+        // Make sure no comments are found
+        if ( div.getElementsByTagName(&quot;*&quot;).length &gt; 0 ) {
+                Expr.find.TAG = function( match, context ) {
+                        var results = context.getElementsByTagName( match[1] );
+
+                        // Filter out possible comments
+                        if ( match[1] === &quot;*&quot; ) {
+                                var tmp = [];
+
+                                for ( var i = 0; results[i]; i++ ) {
+                                        if ( results[i].nodeType === 1 ) {
+                                                tmp.push( results[i] );
+                                        }
+                                }
+
+                                results = tmp;
+                        }
+
+                        return results;
+                };
+        }
+
+        // Check to see if an attribute returns normalized href attributes
+        div.innerHTML = &quot;&lt;a href='#'&gt;&lt;/a&gt;&quot;;
+
+        if ( div.firstChild &amp;&amp; typeof div.firstChild.getAttribute !== &quot;undefined&quot; &amp;&amp;
+                        div.firstChild.getAttribute(&quot;href&quot;) !== &quot;#&quot; ) {
+
+                Expr.attrHandle.href = function( elem ) {
+                        return elem.getAttribute( &quot;href&quot;, 2 );
+                };
+        }
+
+        // release memory in IE
+        div = null;
+})();
+
+if ( document.querySelectorAll ) {
+        (function(){
+                var oldSizzle = Sizzle,
+                        div = document.createElement(&quot;div&quot;),
+                        id = &quot;__sizzle__&quot;;
+
+                div.innerHTML = &quot;&lt;p class='TEST'&gt;&lt;/p&gt;&quot;;
+
+                // Safari can't handle uppercase or unicode characters when
+                // in quirks mode.
+                if ( div.querySelectorAll &amp;&amp; div.querySelectorAll(&quot;.TEST&quot;).length === 0 ) {
+                        return;
+                }
+
+                Sizzle = function( query, context, extra, seed ) {
+                        context = context || document;
+
+                        // Only use querySelectorAll on non-XML documents
+                        // (ID selectors don't work in non-HTML documents)
+                        if ( !seed &amp;&amp; !Sizzle.isXML(context) ) {
+                                // See if we find a selector to speed up
+                                var match = /^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec( query );
+
+                                if ( match &amp;&amp; (context.nodeType === 1 || context.nodeType === 9) ) {
+                                        // Speed-up: Sizzle(&quot;TAG&quot;)
+                                        if ( match[1] ) {
+                                                return makeArray( context.getElementsByTagName( query ), extra );
+
+                                        // Speed-up: Sizzle(&quot;.CLASS&quot;)
+                                        } else if ( match[2] &amp;&amp; Expr.find.CLASS &amp;&amp; context.getElementsByClassName ) {
+                                                return makeArray( context.getElementsByClassName( match[2] ), extra );
+                                        }
+                                }
+
+                                if ( context.nodeType === 9 ) {
+                                        // Speed-up: Sizzle(&quot;body&quot;)
+                                        // The body element only exists once, optimize finding it
+                                        if ( query === &quot;body&quot; &amp;&amp; context.body ) {
+                                                return makeArray( [ context.body ], extra );
+
+                                        // Speed-up: Sizzle(&quot;#ID&quot;)
+                                        } else if ( match &amp;&amp; match[3] ) {
+                                                var elem = context.getElementById( match[3] );
+
+                                                // Check parentNode to catch when Blackberry 4.6 returns
+                                                // nodes that are no longer in the document #6963
+                                                if ( elem &amp;&amp; elem.parentNode ) {
+                                                        // Handle the case where IE and Opera return items
+                                                        // by name instead of ID
+                                                        if ( elem.id === match[3] ) {
+                                                                return makeArray( [ elem ], extra );
+                                                        }
+
+                                                } else {
+                                                        return makeArray( [], extra );
+                                                }
+                                        }
+
+                                        try {
+                                                return makeArray( context.querySelectorAll(query), extra );
+                                        } catch(qsaError) {}
+
+                                // qSA works strangely on Element-rooted queries
+                                // We can work around this by specifying an extra ID on the root
+                                // and working up from there (Thanks to Andrew Dupont for the technique)
+                                // IE 8 doesn't work on object elements
+                                } else if ( context.nodeType === 1 &amp;&amp; context.nodeName.toLowerCase() !== &quot;object&quot; ) {
+                                        var oldContext = context,
+                                                old = context.getAttribute( &quot;id&quot; ),
+                                                nid = old || id,
+                                                hasParent = context.parentNode,
+                                                relativeHierarchySelector = /^\s*[+~]/.test( query );
+
+                                        if ( !old ) {
+                                                context.setAttribute( &quot;id&quot;, nid );
+                                        } else {
+                                                nid = nid.replace( /'/g, &quot;\\$&amp;&quot; );
+                                        }
+                                        if ( relativeHierarchySelector &amp;&amp; hasParent ) {
+                                                context = context.parentNode;
+                                        }
+
+                                        try {
+                                                if ( !relativeHierarchySelector || hasParent ) {
+                                                        return makeArray( context.querySelectorAll( &quot;[id='&quot; + nid + &quot;'] &quot; + query ), extra );
+                                                }
+
+                                        } catch(pseudoError) {
+                                        } finally {
+                                                if ( !old ) {
+                                                        oldContext.removeAttribute( &quot;id&quot; );
+                                                }
+                                        }
+                                }
+                        }
+
+                        return oldSizzle(query, context, extra, seed);
+                };
+
+                for ( var prop in oldSizzle ) {
+                        Sizzle[ prop ] = oldSizzle[ prop ];
+                }
+
+                // release memory in IE
+                div = null;
+        })();
+}
+
+(function(){
+        var html = document.documentElement,
+                matches = html.matchesSelector || html.mozMatchesSelector || html.webkitMatchesSelector || html.msMatchesSelector;
+
+        if ( matches ) {
+                // Check to see if it's possible to do matchesSelector
+                // on a disconnected node (IE 9 fails this)
+                var disconnectedMatch = !matches.call( document.createElement( &quot;div&quot; ), &quot;div&quot; ),
+                        pseudoWorks = false;
+
+                try {
+                        // This should fail with an exception
+                        // Gecko does not error, returns false instead
+                        matches.call( document.documentElement, &quot;[test!='']:sizzle&quot; );
+
+                } catch( pseudoError ) {
+                        pseudoWorks = true;
+                }
+
+                Sizzle.matchesSelector = function( node, expr ) {
+                        // Make sure that attribute selectors are quoted
+                        expr = expr.replace(/\=\s*([^'&quot;\]]*)\s*\]/g, &quot;='$1']&quot;);
+
+                        if ( !Sizzle.isXML( node ) ) {
+                                try {
+                                        if ( pseudoWorks || !Expr.match.PSEUDO.test( expr ) &amp;&amp; !/!=/.test( expr ) ) {
+                                                var ret = matches.call( node, expr );
+
+                                                // IE 9's matchesSelector returns false on disconnected nodes
+                                                if ( ret || !disconnectedMatch ||
+                                                                // As well, disconnected nodes are said to be in a document
+                                                                // fragment in IE 9, so check for that
+                                                                node.document &amp;&amp; node.document.nodeType !== 11 ) {
+                                                        return ret;
+                                                }
+                                        }
+                                } catch(e) {}
+                        }
+
+                        return Sizzle(expr, null, null, [node]).length &gt; 0;
+                };
+        }
+})();
+
+(function(){
+        var div = document.createElement(&quot;div&quot;);
+
+        div.innerHTML = &quot;&lt;div class='test e'&gt;&lt;/div&gt;&lt;div class='test'&gt;&lt;/div&gt;&quot;;
+
+        // Opera can't find a second classname (in 9.6)
+        // Also, make sure that getElementsByClassName actually exists
+        if ( !div.getElementsByClassName || div.getElementsByClassName(&quot;e&quot;).length === 0 ) {
+                return;
+        }
+
+        // Safari caches class attributes, doesn't catch changes (in 3.2)
+        div.lastChild.className = &quot;e&quot;;
+
+        if ( div.getElementsByClassName(&quot;e&quot;).length === 1 ) {
+                return;
+        }
+
+        Expr.order.splice(1, 0, &quot;CLASS&quot;);
+        Expr.find.CLASS = function( match, context, isXML ) {
+                if ( typeof context.getElementsByClassName !== &quot;undefined&quot; &amp;&amp; !isXML ) {
+                        return context.getElementsByClassName(match[1]);
+                }
+        };
+
+        // release memory in IE
+        div = null;
+})();
+
+function dirNodeCheck( dir, cur, doneName, checkSet, nodeCheck, isXML ) {
+        for ( var i = 0, l = checkSet.length; i &lt; l; i++ ) {
+                var elem = checkSet[i];
+
+                if ( elem ) {
+                        var match = false;
+
+                        elem = elem[dir];
+
+                        while ( elem ) {
+                                if ( elem[ expando ] === doneName ) {
+                                        match = checkSet[elem.sizset];
+                                        break;
+                                }
+
+                                if ( elem.nodeType === 1 &amp;&amp; !isXML ){
+                                        elem[ expando ] = doneName;
+                                        elem.sizset = i;
+                                }
+
+                                if ( elem.nodeName.toLowerCase() === cur ) {
+                                        match = elem;
+                                        break;
+                                }
+
+                                elem = elem[dir];
+                        }
+
+                        checkSet[i] = match;
+                }
+        }
+}
+
+function dirCheck( dir, cur, doneName, checkSet, nodeCheck, isXML ) {
+        for ( var i = 0, l = checkSet.length; i &lt; l; i++ ) {
+                var elem = checkSet[i];
+
+                if ( elem ) {
+                        var match = false;
+
+                        elem = elem[dir];
+
+                        while ( elem ) {
+                                if ( elem[ expando ] === doneName ) {
+                                        match = checkSet[elem.sizset];
+                                        break;
+                                }
+
+                                if ( elem.nodeType === 1 ) {
+                                        if ( !isXML ) {
+                                                elem[ expando ] = doneName;
+                                                elem.sizset = i;
+                                        }
+
+                                        if ( typeof cur !== &quot;string&quot; ) {
+                                                if ( elem === cur ) {
+                                                        match = true;
+                                                        break;
+                                                }
+
+                                        } else if ( Sizzle.filter( cur, [elem] ).length &gt; 0 ) {
+                                                match = elem;
+                                                break;
+                                        }
+                                }
+
+                                elem = elem[dir];
+                        }
+
+                        checkSet[i] = match;
+                }
+        }
+}
+
+if ( document.documentElement.contains ) {
+        Sizzle.contains = function( a, b ) {
+                return a !== b &amp;&amp; (a.contains ? a.contains(b) : true);
+        };
+
+} else if ( document.documentElement.compareDocumentPosition ) {
+        Sizzle.contains = function( a, b ) {
+                return !!(a.compareDocumentPosition(b) &amp; 16);
+        };
+
+} else {
+        Sizzle.contains = function() {
+                return false;
+        };
+}
+
+Sizzle.isXML = function( elem ) {
+        // documentElement is verified for cases where it doesn't yet exist
+        // (such as loading iframes in IE - #4833)
+        var documentElement = (elem ? elem.ownerDocument || elem : 0).documentElement;
+
+        return documentElement ? documentElement.nodeName !== &quot;HTML&quot; : false;
+};
+
+var posProcess = function( selector, context, seed ) {
+        var match,
+                tmpSet = [],
+                later = &quot;&quot;,
+                root = context.nodeType ? [context] : context;
+
+        // Position selectors must be done after the filter
+        // And so must :not(positional) so we move all PSEUDOs to the end
+        while ( (match = Expr.match.PSEUDO.exec( selector )) ) {
+                later += match[0];
+                selector = selector.replace( Expr.match.PSEUDO, &quot;&quot; );
+        }
+
+        selector = Expr.relative[selector] ? selector + &quot;*&quot; : selector;
+
+        for ( var i = 0, l = root.length; i &lt; l; i++ ) {
+                Sizzle( selector, root[i], tmpSet, seed );
+        }
+
+        return Sizzle.filter( later, tmpSet );
+};
+
+// EXPOSE
+
+window.Sizzle = Sizzle;
+
+})();
</ins><span class="cx">\ No newline at end of file
</span></span></pre>
</div>
</div>

</body>
</html>