title: Execute specific code when specific button is click one it
body: <p>I have problem to only execute one of the script at a time when one of the button is click. The code execute 2 script together when the button is click. How can I only execute one script at a time and specific button execute specific script. Thanks for the help. Below is my code. </p>
  
  <pre><code>&lt;html&gt;
  &lt;head&gt;
  &lt;script language="javascript" type="text/javascript"&gt;
      function popup(){
          window.location = 'testing.php?run=shell';
      }
      function popdown(){
          window.location = 'testing.php?run=shell';
      }
  &lt;/script&gt;
  &lt;/head&gt;
  &lt;body&gt;
  &lt;input type="button" onclick="popup()" value="popup"&gt;
  &lt;?php
  if(isset($_GET['run']) &amp;&amp; ($_GET['run'] == 'shell')){
      echo shell_exec('sh bash_test.sh');
  }
  ?&gt;
  &lt;input type="button" onclick="popdown()" value="popdown"&gt;
  &lt;?php
  if(isset($_GET['run']) &amp;&amp; ($_GET['run'] == 'shell')){
      echo shell_exec('sh bash_run.sh');
  }
  ?&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>