title: Can't seem to get CURLOPT_SSL_VERIFYPEER to behave in PHP
body: <p>Ultimately, I'm trying to set up a simple site with links that initiate a cURL POST using basic auth. The href of the link points to <code>blah.php?dothething</code>.</p>
  
  <p>In the php file, I have</p>
  
  <pre><code>if ($_SERVER['QUERY_STRING'] == 'dothething') {
      $ch = curl_init();
      curl_setopt($ch, CURLOPT_URL, "https://blah/");
      curl_setopt($ch, CURLOPT_POST, 1);
      curl_setopt($ch, CURLOPT_POSTFIELDS, "thing=1&amp;do=true");
      curl_setopt($ch, CURLOPT_USERPWD, "user:pwd");
      curl_setopt($ch, CURLOPT_PIPEWAIT, TRUE); //POST takes about 10 sec to process
      curl_setopt($ch, CURLOPT_SSLVERIFYPEER, FALSE); //self-signed cert
      curl_exec($ch);
      curl_close($ch);
  }
  </code></pre>
  
  <p>When I visit the link, I get:</p>
  
  <p><b>Warning</b>:  curl_setopt() expects parameter 2 to be integer, string given in <b>blah.php</b> on line <b>31</b><br />
  <b>Warning</b>:  curl_setopt() expects parameter 2 to be integer, string given in <b>blah.php</b> on line <b>32</b><br /></p>
  
  <p>I've tried <code>TRUE</code>, <code>true</code>, <code>"true"</code>, and <code>1</code>, and have gotten the same error every time.</p>
  
  <p>I'm running this on PHP v7.0.14 on DreamHost. Looks like these options have been available since v7.0.7, are they maybe just not available in DreamHost's PHP? If that's the case, is there any way to not validate the cert, other than running it somewhere else?</p>