Loader on PHP form submit
<p>I'm trying to establish a 'Loader' upon user submitting the form (PHP). Here's what I've got so far which doesn't seems to be working.</p>

<p>Can you please highlight where could be the potential issue?</p>

<pre><code>&lt;!DOCTYPE html&gt;
&lt;html lang="en"&gt;
&lt;head&gt;
    &lt;meta charset="UTF-8"&gt;
    &lt;title&gt;Document&lt;/title&gt;
    &lt;script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"&gt;&lt;/script&gt;

    &lt;script type="text/javascript"&gt;
     $('#myForm').submit(function() {
       $('#loaderImg').show(); 
       return true;
     });
    &lt;/script&gt;
&lt;/head&gt;

&lt;body&gt;
&lt;div class="wrapper"&gt;
    &lt;form action="" method="post" id="myForm" name="myForm"&gt;
        &lt;img src="../images/loader.gif" alt="loader1" style="display:none; height:30px; width:auto;" id="loaderImg"&gt;
        &lt;input type="submit" id="clicknow" value="Click the button to go to another page"&gt;
    &lt;/form&gt;

&lt;/div&gt;
&lt;/body&gt;
&lt;/html&gt;
</code></pre>