title: Receive varying variable inputs from PHP into c++
body: <p>I have a program that needs to be sent the following variables:</p>
  
  <p><code>Bool</code> <code>int</code> <code>string</code> <code>vector&lt;int&gt;</code> <code>vector&lt;string&gt;</code></p>
  
  <p>This will come from a <code>PHP</code> call as I've looked into <a href="https://stackoverflow.com/questions/4279003/execute-c-program-with-php-script"><strong>here</strong></a> and <a href="https://stackoverflow.com/questions/11789095/run-c-script-in-php"><strong>here</strong></a>.</p>
  
  <p>Looking at <strong><a href="https://stackoverflow.com/questions/3024197/what-does-int-argc-char-argv-mean">this question</a></strong> about <code>(int argc, char** argv[])</code>, I know that you can pass various arguments to a program that it needs so to run, but these are all in the form of a <a href="http://www.cplusplus.com/doc/tutorial/ntcs/" rel="nofollow noreferrer"><strong>Character Sequence</strong></a>.</p>
  
  <p><strong>So my question is:</strong> If it is possible, how do you go about sending across multiple varying variables in a <code>PHP</code> call to a <code>C++</code> program?</p>
  
  <p><strong>EDIT</strong> (Question continued) ...and what would the function call look like?</p>
  
  <p>Is it as simple as not using the <code>(int argc, char** argv[])</code> and just doing:</p>
  
  <pre><code>int main(bool var1, int var2, std::vector&lt;std::string&gt; var3, std::string var4)
  {
  ...
  }
  </code></pre>
  
  <p>Because that seems to make <code>(int argc, char** argv[])</code> a tad redundant?</p>