title: how to pass argument in php for executing shell command?
body: <p>Here is the program listed below. I am trying to run the shell command from php so I have written the following code:</p>
  
  <pre><code>&lt;?php    
  $argument1 = $argv[1];    
  $output = shell_exec('sudo whois ');    
  echo "&lt;pre&gt;$output&lt;/pre&gt;";    
  ?&gt; 
  </code></pre>
  
  <p>But every time I execute the command it get executed but doesn't display output. Only shows the option.</p>
  
  <p>My command in shell is 
  <code>php filename.php google.com</code></p>