title: Curl script not working for some of the url
body: <p>I want to execute a url for which i am using curl. </p>
  
  <p>I have following curl script: </p>
  
  <pre><code>$messageUrl = "http://bulksms.mysmsmantra.com:8080/WebSMS/SMSAPI.jsp?username=myusername&amp;password=pass&amp;sendername=sender&amp;mobileno=mob&amp;message=hi";
  //$content=file_get_contents($messageURl);
  $ch = curl_init($messageUrl);
  $fp = fopen("message.txt", "w");
  
  curl_setopt($ch, CURLOPT_FILE, $fp);
  curl_setopt($ch, CURLOPT_HEADER, 0);
  
  curl_exec($ch);
  curl_close($ch);
  fclose($fp);
  </code></pre>
  
  <p>When i execute this script on my local server it runs fine that is the sms is sent to the user and message is successfully written to the message.txt file.</p>
  
  <p>But when i upload it on the server (hostgator). It does not work.</p>
  
  <p>I had a talk with hosting provider. Earlier curl was not enabled but was enabled after the conversation. Even then the above example does not run. </p>
  
  <p>I tried to change the above code by calling the simple url: <a href="http://google.com" rel="nofollow">http://google.com</a>. It executes properly on the server with some text written in the message.txt file .</p>
  
  <p>I fail to understand the reason behind this. </p>