title: I'm trying to fetch data with curl
body: <p>I'm trying to fetch data with curl. When I <code>print_r</code>, the page is blank. Can someone please explain why this is not working?</p>
  <pre><code>$headers = array();
  $headers[] = 'Sec-Ch-Ua: \&quot; Not A;Brand\&quot;;v=\&quot;99\&quot;, \&quot;Chromium\&quot;;v=\&quot;96\&quot;, \&quot;Google Chrome\&quot;;v=\&quot;96\&quot;';
  $headers[] = 'Sec-Ch-Ua-Mobile: ?0';
  $headers[] = 'Sec-Ch-Ua-Platform: \&quot;Windows\&quot;';
  $headers[] = 'Upgrade-Insecure-Requests: 1';
  $headers[] = 'User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.110 Safari/537.36';
  $headers[] = 'Referer: https://www.sokmarket.com.tr/';
  $urun_adi_ara=&quot;bonbon nane&quot;;
  //$urun_adi_ara=str_replace(&quot; &quot;,&quot;+&quot;,$urun_adi_ara);
  $aranan_kelime=urlencode($urun_adi_ara);
  $url=&quot;https://www.sokmarket.com.tr/arama/&quot;.$aranan_kelime;
  $url  =curl_init ($url);
  curl_setopt_array($url,[CURLOPT_RETURNTRANSFER=&gt;true,CURLOPT_TIMEOUT_MS=&gt;4000,CURLOPT_FOLLOWLOCATION=&gt;true,CURLOPT_USERAGENT=&gt;true,
   CURLOPT_HEADER=&gt;0,CURLOPT_HTTPHEADER=&gt;$headers, CURLOPT_VERBOSE=&gt;1,CURLOPT_SSL_VERIFYPEER=&gt;0,
   CURLOPT_SSL_VERIFYHOST=&gt;0,
  
   CURLOPT_FAILONERROR=&gt;0]);
   $result = curl_exec($url);
  print_r($result);
  curl_close($url);
  </code></pre>