I'm having problems to figure out why jquery string counter won't show me the expected result.
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
<script type="text/javascript">
var count = $('h1').length;
alert(count);
</script>
</head>
<body>
<h1>some text</h1>
</body>
</html>
the result should be with this example 9, but instead I'm getting 0