title: Why am I getting a "function not defined" error when there are 2 functions in the script tag?
body: <p>The script tag part in <code>&lt;head&gt;</code>:</p>
  
  <pre><code>  function reload()
    {
       //some code
  
  
    }
    function bookconfirm(clickinfo)
    {
          //some code
    }
  </code></pre>
  
  <p>The part that are calling them:  </p>
  
  <pre><code>           &lt;select name="city" onchange="reload()"&gt;
  
            &lt;td&gt;&lt;button type="button" onclick="bookconfirm(&lt;?php echo $c;?&gt;)"&gt;Book&lt;/button&gt;&lt;/td&gt;
  </code></pre>
  
  <p>Errors:  </p>
  
  <pre><code>             Uncaught ReferenceError: reload is not defined at HTMLSelectElement.onchange
  
  
          Uncaught ReferenceError: bookconfirm is not defined  at HTMLButtonElement.onclick 
  </code></pre>
  
  <p>I'm probably unable to understand how functions work in js or something , thanks for your time and knowledge.</p>