Ever since I switched to HTTPS I've had problems with using CURL to connect to Worldpay. Submit code here:
if(isset($_POST['submitw']))
{
$ch = curl_init("https://secure-test.worldpay.com/wcc/purchase");
curl_setopt ($ch, CURLOPT_HEADER, 0);
curl_setopt ($ch, CURLOPT_POST, 1);
curl_setopt ($ch, CURLOPT_POSTFIELDS, $urlstring);
curl_setopt ($ch, CURLOPT_FOLLOWLOCATION, 1);
curl_setopt ($ch, CURLOPT_REFERER, "https://www.mycrapsite.co.uk/checkout.php");
curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 0);
$data = curl_exec ($ch);
curl_close ($ch);
}
I thought it was not connecting to Worldpay but it is. What is happening is that my page (has an absolute) still shows and is overlaying it! If I check page source I can see the Worldpay page followed by my page. Never heard of two web pages merged into 1 before!
Any ideas? Ta.
if(isset($_POST['submitw']))
{
$ch = curl_init("https://secure-test.worldpay.com/wcc/purchase");
curl_setopt ($ch, CURLOPT_HEADER, 0);
curl_setopt ($ch, CURLOPT_POST, 1);
curl_setopt ($ch, CURLOPT_POSTFIELDS, $urlstring);
curl_setopt ($ch, CURLOPT_FOLLOWLOCATION, 1);
curl_setopt ($ch, CURLOPT_REFERER, "https://www.mycrapsite.co.uk/checkout.php");
curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 0);
$data = curl_exec ($ch);
curl_close ($ch);
}
I thought it was not connecting to Worldpay but it is. What is happening is that my page (has an absolute) still shows and is overlaying it! If I check page source I can see the Worldpay page followed by my page. Never heard of two web pages merged into 1 before!
Any ideas? Ta.
Comment