Wrox Programmer Forums
Go Back   Wrox Programmer Forums > PHP/MySQL > PHP How-To
|
PHP How-To Post your "How do I do this with PHP?" questions here.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the PHP How-To section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 21st, 2007, 10:45 AM
Registered User
 
Join Date: Nov 2006
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default cURL is resubmitting the page

Hello,

I have a strange problem with using cURL on PHP. After cURL submits the data to another URL (ASP page), and the script reaches the bottom of the main condition, the whole page is re-submitted again.

And I know, it is re-submitting, because I have a prevention measure in place "Attempted Duplicate transaction", when the same Ref. comes in again for re-insert into mySQL database.

Has anyone come across a similar problem ?

I have been trying to resolve this since last 2 hrs, and can't get any clue.

This is the general setup of my cURL call.

$ch = curl_init();
$callURL = "http://the-address-to-send-data" ;

curl_setopt ($ch, CURLOPT_HEADER, false);
curl_setopt ($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt ($ch, CURLOPT_URL, "$callURL");

// Make the request
$TransASPresponse = curl_exec($ch);

// Close the curl session
curl_close ($ch);

Any ideas on why could this be happening ?

Thanks,
Bij.
 
Old September 23rd, 2008, 04:25 PM
Registered User
 
Join Date: Sep 2008
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I am having the same problem when submitting a credit card transaction to Authorize.net using cURL. (Also as a side note, we're using CodeIgniter as a framework) Anyone out there with any ideas? Would be greatly appreciated...






Similar Threads
Thread Thread Starter Forum Replies Last Post
why isn't CURL logging me in ? jjk2 Beginning PHP 1 October 5th, 2008 07:29 PM
resubmitting how to display message box tsuersrb Excel VBA 1 March 10th, 2008 07:06 AM
curl spbharti Pro PHP 1 April 20th, 2006 02:34 PM
PHP CURL set root domain mfoozzz PHP How-To 0 April 6th, 2006 04:26 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.