NYCPHP Meetup

NYPHP.org

[nycphp-talk] PHP HTTP POST not working

Daniel Convissor danielc at analysisandsolutions.com
Fri Jan 18 10:30:32 EST 2008


Hi Jason:

On Wed, Jan 16, 2008 at 08:48:20PM -0800, Jason Sia wrote:

Whenever you do anything outside your script (like running a query, 
opening a file or using cURL) you _must_ check the response and handle 
any errors.

>         $result=curl_exec ($ch);

if ($result == false)
{
    $error = curl_errno($ch) . ': ' . curl_error($ch);
    your_error_handler_logger_thingie($error);
    exit;
}

>         curl_close ($ch);

--Dan

-- 
 T H E   A N A L Y S I S   A N D   S O L U T I O N S   C O M P A N Y
            data intensive web and database programming
                http://www.AnalysisAndSolutions.com/
 4015 7th Ave #4, Brooklyn NY 11232  v: 718-854-0335 f: 718-854-0409



More information about the talk mailing list