title: Working with PHP shell_exec and SpiderMonkey Javascript Shell
body: <p>Let say I have this code in a JS file called plus2.js:</p>
  
  <pre><code>function plus2(n){
      print (n+2);
  };
  plus2(n);
  </code></pre>
  
  <p>That's how it can be exacuted via PHP shell_exec:</p>
  
  <pre><code>echo shell_exec('js -f plus2.js');
  </code></pre>
  
  <p>Which doesn't return anythig because I have not informed a value to "n".</p>
  
  <p>And that's the question: how can I pass a value to "n" via PHP shell_exec?</p>