 <p>Your <code>ready</code> event is incorrect.<br> The recommended way is:</p> <pre><code>$(document).ready(...); </code></pre> <p>Or this: (though <strong>not</strong> recommended by jQuery)</p> <pre><code>$().ready(...); </code></pre> <p>Or:</p> <pre><code>$(function() { ... }); </code></pre> <p><a href="http://api.jquery.com/ready/" rel="nofollow">http://api.jquery.com/ready/</a></p>