title: Execute sh script with parameters
body: <p>I have self-writed sh script, which contains contruction like "cd directory"</p>
  
  <p>It is successfully running through terminal</p>
  
  <pre><code>. /path/to/script.sh param1 param2
  </code></pre>
  
  <p>I want to run this script through PHP</p>
  
  <pre><code>shell_exec('. /path/to/script.sh param1 param2');
  
  shell_exec('. /path/to/script.sh "param1" "param2"');
  </code></pre>
  
  <p>not running correctly</p>
  
  <pre><code>shell_exec('/bin/bash /path/to/script.sh param1 param2');
  </code></pre>
  
  <p>running, but directory changing is not working</p>
  
  <p>Please, help. Thank you in advance</p>