?
Solved

cURL returns bool(false) after execution -- Never happened before

Posted on 2009-04-15
1
Medium Priority
?
226 Views
Last Modified: 2012-05-06
Hello everyone.

I put together a cURL setup that was working about a week ago and now it is not.  I am wondering if I am doing something wrong to prompt this.  The script hits a URL that is supposed to upload some XML.  When I hit the URL manually, the update on the XML works fine.  However, when I try to hit it via cURL, I just get back a bool(false) when I do a var_dump on the $data variable.

Any ideas as to what could possibly be wrong?

            
$ch = curl_init();
$url = "link to whatever";
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_TIMEOUT, 60);
$data = curl_exec($ch);
curl_close($ch);

Open in new window

0
Comment
Question by:Minnickweb
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 

Accepted Solution

by:
Minnickweb earned 0 total points
ID: 24149250
Figured it out.  Found a very nice troubleshooting cURL script that helped me detect that the problem was with the URL :)
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There are two main kinds of selectors in CSS: One is base selector like h1, h2, body, table or any existing HTML tags.  For instance, the following rule sets all paragraphs (<p> elements) to red: (CODE) CSS also allows us to define our own custom …
JavaScript has plenty of pieces of code people often just copy/paste from somewhere but never quite fully understand. Self-Executing functions are just one good example that I'll try to demystify here.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…

649 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question