MooTools: search query is not the only result only in IE

I am new to MooTools, I need to modify some existing code (normaly I use jQuery).

When I browse dom using MooTools, in IE I get other results (invalid results).

Part of the html source, for example:

<a class="dmnmlk" rel="dmnml='post'" /></a>
<a href="#" /></a>
<a href="#" /></a>
<a class="blueLink" rel="external" href="http://www.linkedin.com" /></a>
<a rel="external,twitter='txxxxxxxxxxxxxxxxx',data={'border-color':'#634e42','chrome':'noheader nofooter transparent',polite:'polite',limit:10}" class="twitter-timeline" href="https://twitter.com/test" /></a>
<a rel="mlink" /></a>
<a rel="mlink" /></a>
<a rel="mlink" /></a>
<a rel="mlink" /></a>
<a><span /></a>
<a rel="mlink" /></a>
<a rel="mlink" class="selected" /></a>
<a rel="mlink" class="selected" /></a>
<a rel="mlink" class="selected" /></a>
<a rel="svg" class="sprites menuLogo" href="#" title="Go to startpage" /></a>
<div class="resources hidden">
   <div class="dialog">
     .............
   <a class="button" rel="modalresult='ok'>OK</a>
   <a class="button" rel="modalresult='cancel'>Cancel</a>
</div>

var aElems = $('a[rel]:not(.resources a[rel],.disabled),a[href*="#"]:not(a[rel])');

alert( aElems.length );

In a different browser than IE: count is 14 In IE only: count is 2

Im using the latest version of mootools.

Can someone explain what is happening? What can I do about this?

EDIT: EXPLANATION WHAT I TRY TO DO:

rel html . , data HTML5, IE ( XHTML strict). :

  • , DOM

  • , rel html

  • , , .

  • ajax, , html , rel.

  • , rel , .

( jQuery), , "AjaxQuery", :

 // Extend the ajaxquery class
TAjaxQuery.prototype.setupPage = function() // Will be called automaticly
{
 var o = this;

o.onAjaxFoundRelAttrMlink = function( oSender, oData ) // Called when rel="mlink" is found
{
  // oData.target    // Target element
  // oData.rel.mlink // parsed rel attribute
  $(oData.target).bind( 'click', function(e) // i know this is jquery
  {
    // do something
  }); 

  // ..... etc
};

};

, . , rel , . - . not(.resources a[rel]) .

, .

+4

All Articles