[jQuery] Empty string as selector returns an object
Hi
I was a bit surprised to find that $("") has size one. Firebug tells
me that the object's node name is "#document". Is this expected
behaviour?
Thanks
Paul
<html>
<head>
<title>selectors</title>
<script type="text/javascript" src="http://code.jquery.com/
jquery.js"></script>
<script type="text/javascript">
$(document).ready(function () {
$("").each(function () {
console.dir(this);
});
});
</script>
</head>
<body></body>
</html>