curl-and-php
cURL error
Date: Mon, 8 Apr 2002 22:51:17 +0200 (CEST)
I'm working on a (XML) connection between Bibit (paymentsystem) and PHP for
a webshop. The complete code (and classes) can be downloaded on
http://www.xs4all.nl/~emtoonst/bibitxml.zip.
I get a strange error when I call sendorder.php:
curl error: 1079329032 -
My server configuration :
libcurl 7.9.2 (OpenSSL 0.9.6b)
PHP Version 4.1.2 Apache/1.3.22 (Unix)
'./configure' '--with-config-file-path=/etc' '--with-zlib' '--enable-
bcmath' '--with-pdflib' '--enable-calendar' '--with-db' '--with-gdbm' '--
enable-ftp' '--with-gd' '--enable-gd-native-ttf' '--with-freetype-dir' '--
with-imap=imap-2001.RELEASE-CANDIDATE.1' '--with-mysql' '--enable-trans-
sid' '--enable-sockets' '--enable-memory-limit' '--enable-track-vars' '--
enable-xslt' '--with-xslt-sablot' '--with-curl'
fragments of code that generates the error:
if ( $result === false )
{
// get error in array form
$errorData = $bibit->getErrorData(true);
echo $errorData["type"] ." error: ". $errorData["error"]["code"] ." - ".
$errorData["error"]["message"] ."<br>";
}
function getErrorData($asArray = false, $allErrors = false )
{
// first check for bibit errors, because if they exist, there shouldn't be
any other errors
$errors["bibit"] = $this->errorMsgs["bibit"];
$errors["curl"] = $this->errorMsgs["curl"];
if ( $this->parser )
$errors["xml"] = array_merge((array)$this->parser->errorMsgs, (array)$this-
>errorMsgs["xml"]);
else
$errors["xml"] = (array)$this->errorMsgs["xml"];
foreach( $errors as $type => $array )
{
if ( sizeof((array)$array) > 0 )
{
if ( !$allErrors )
$array = $array[sizeof($array)-1];
if ( $asArray )
return array("type" => $type, "error".($allErrors?"s":"") => $array);
else
{
if ( $allErrors )
{
$tmp = "The following '". $type ."' type errors were returned:<br>";
foreach( $array as $error )
$tmp .= $error["message"] ." (Error #". $error["code"] .")<br>";
}
else
{
$tmp = "The following '". $type ."' type error occured last:<br>";
$tmp .= $array["message"] ." (Error #". $array["code"] .")<br>";
}
return $tmp;
}
}
}
return false;
}
Can someone help me on this?
Received on 2002-04-09