If you wanted the code to be universal, you could do:
var uls = document.getElementsByTagName("ul");
for ( var u = 0; u < uls.length; ++u )
var ul = uls[u];
if ( ul.getAttribute("data-abc") != null )
... same code as above performed on the ul object ...
That should work even in MSIE 7.