title: Executing a .sh file with php
body: <p>I have written a very simple Hello World script as a bash file and saved it on my desktop.</p>
  
  <p>I want to execute this file when a Submit button is pressed.</p>
  
  <p>The following script works fine and I see the Hello World on the firefox webbrowser:</p>
  
  <pre><code>   &lt;?php
  
       echo shell_exec('sh /home/administrator/Desktop/Helloworld.sh');
  
      ?&gt;
  </code></pre>
  
  <p>However the following script does not give me any result:</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
    &lt;html&gt;
  
  &lt;body&gt;
  
  &lt;?php
  if (isset($_POST['Submit1'])) {
  
   echo shell_exec('sh /home/administrator/Desktop/Helloworld.sh');
    }
  
   ?&gt;
  
  &lt;Input Type = "Submit" Name ="Submit1" Value = "Save Parameters"&gt;
  
  
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>Any idea why? I don't get any errors in my log file.</p>