title: Installing PHP Project Dependencies with Composer
body: <p>I am trying to install Nette2.3.1 using Composer (on XAMPP). In c:\x\php folder I run this command: </p>
  
  <pre><code>composer create-project nette/sandbox myprojectname
  </code></pre>
  
  <p>When I do this, getting following error:</p>
  
  <blockquote>
    <p>[Seld\JsonLint\ParsingException] "c:\x\php\php.exe" does not contain
    valid JSON Parse error on line 1: MZÉ ♥   ♦       ╕ ^ Expected one of:
    'STRING', 'NUMBER', 'NULL', 'TRUE', 'FALSE', '{', '['</p>
  </blockquote>
  
  <p>I tried all these options to no avail:</p>
  
  <ol>
  <li>removed the project directory and tried</li>
  <li>ran this command inside htdocs folder</li>
  <li>ran this through PHP JetBrains console</li>
  <li>made sure that the Composer version is the latest one</li>
  </ol>
  
  <h2>What was wrong?</h2>
  
  <p>This was what went wrong: </p>
  
  <ol>
  <li><p>I installed xampp while anti-virus is running - i got a warning but chose to ignore that. Consequently php.exe was corrupted and messed up the whole thing for me. </p></li>
  <li><p>PATH variables under my user wasn't updated with php.exe path. Though system variable is updated, it is still a mystery to me why this became an issue.</p></li>
  </ol>
  
  <p>How I did to correct this:</p>
  
  <p>Removed xampp altogether, cleared composer cache and installed wamp this time and created project for nette sandbox. This worked fine. In all fairness xampp would have worked as well had I installed it with av disabled and PATH variables properly updated.</p>