title: Php Curl doesn't work on just one website
body: <p>i've an error very very strange.
  I need to access this website: <a href="http://sub.example.com/" rel="nofollow noreferrer">http://sub.example.com/</a> with cURL. From localhost i've no problem as well as if i use cURL from command line or browser to access the website.</p>
  
  <p>I'm using this code on my Siteground server:</p>
  
  <pre><code>&lt;?php 
  
  
      $url="http://sub.example.com/";
      $agent= 'Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.0.3705; .NET CLR 1.1.4322)';
  
      $ch = curl_init();
      curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
      curl_setopt($ch, CURLOPT_VERBOSE, true);
      curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
      curl_setopt($ch, CURLOPT_USERAGENT, $agent);
      curl_setopt($ch, CURLOPT_URL,$url);
  
      $result=curl_exec($ch);
      var_dump($result);
  
  
      ?&gt;
  </code></pre>
  
  <p>and i get <strong>$result = false</strong>.</p>
  
  <p>If i use Try / Catch i get: <strong>Curl failed with error #6: Could not resolve host</strong></p>
  
  <p>I've also tried to substitute $url with another website's url and it always works (http and https, domain and subdomain, on my server and external)!</p>
  
  <p>I spent already a day trying to solve this, please help me!</p>
  
  <p>Thank you in advance, Luca</p>