JQuery button click function not working <p>I'm new to JQuery and my problem is that I have a button in a modal such that when I click it, a JQuery script is run. Pieces of code so far:</p> <pre><code>&lt;a id="submitMe" class="btn btn-default btn-primary"&gt;Submit&lt;/a&gt; $(document).ready(function (){ $("#submitMe").click(function(){ alert("Something to alert"); }); }); </code></pre> <p>Thanks for all your help!</p>