cURL / Mailing Lists / curl-and-php / Single Mail

curl-and-php

slow curl post

From: <chad_at_buglogic.com>
Date: Mon, 1 Mar 2004 10:18:23 -0500

hello..

i'm trying to connect to a secure payment processing gateway. i'm successfully getting a response but it takes like over a minute. here is my code..

$params="ssl_test_mode=TRUE&ssl_customer_code=99&ssl_salestax=$ssl_salestax&ssl_merchant_id=$ssl_merchant_id&ssl_user_id=$ssl_user_id&ssl_pin=$ssl_pin&ssl_card_number=$ssl_card_number&ssl_exp_date=$ssl_exp_date&";
$params.="ssl_amount=$ssl_amount&ssl_show_form=$ssl_show_form&ssl_cvv2=$ssl_cvv2&ssl_cvv2cvc2=$ssl_cvv2cvc2&";
$params.="ssl_avs_address=$ssl_avs_address&ssl_avs_zip=$ssl_avs_zip&ssl_result_format=$ssl_result_format&";
   

  $ch = curl_init("https://www2.viaKLIX.com/process.asp");
   curl_setopt($ch, CURLOPT_POST,1);
 curl_setopt($ch, CURLOPT_HEADER, 0);
 curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 0);
  curl_setopt ($ch, CURLOPT_TIMEOUT, 20);
   curl_setopt ($ch, CURLOPT_SSL_VERIFYPEER, 0);
   curl_setopt ($ch, CURLOPT_SSL_VERIFYHOST, 0);
   curl_setopt($ch, CURLOPT_NOPROGRESS,1);
   curl_setopt($ch, CURLOPT_POSTFIELDS,$params);
  // curl_setopt($ch, CURLOPT_URL,$_url);
   //curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 2);
   curl_setopt($ch, CURLOPT_USERAGENT, $defined_vars['HTTP_USER_AGENT']);
   curl_setopt($ch, CURLOPT_RETURNTRANSFER,1);
   $result=curl_exec ($ch);
   curl_close ($ch);
Received on 2004-03-01