Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Recommended Posts

Posted

Hi. i just installed and tried to use the Protx Form Payment Module.

 

I ran into an error with this though.

 

I used the form to download a bit of software.

 

SagePay failed the request, saying that they needed a delivery postcode.

 

 

I remembered that this had been fixed on my site using protx, so I looked at the code.

At about line 250 of the code in sagepay_form.php there is this code.

 

 

     $plain .= "DeliveryAddress=" . $delivery_address . "&";
     $plain .= "DeliveryPostCode=" . $order->delivery['postcode'] . "&";


 

Replacing it with the code below fixes this problem

 

 

 


     if (strlen($delivery_address) < 10) {
       $plain .= "DeliveryAddress=" . $billing_address . "&";
       $plain .= "DeliveryPostCode=" . $order->billing['postcode'] . "&";
     } else {
       $plain .= "DeliveryAddress=" . $delivery_address . "&";
       $plain .= "DeliveryPostCode=" . $order->delivery['postcode'] . "&";
     }


 

It fixed it for me.

 

I hope this help someone else too.

 

Chris.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...