Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

error in checkout_confirmation.php


profesher

Recommended Posts

Hello everyone!

 

I'm working on a site for a wholesaler with only local clients and delivery included free of cost in every order so I don't need neither payment or shipping methods on the checkout, just the addresses. So I made a few changes to the checkout procedure, for instance, I unified the checkout_shipping and the checkout_payment files on one checkout_address.php file. That way, the user can view and change both shipping and payment addresses on the same page. When they click on the change address button (there is one button for each address) they are linked to checkout_address_change.php wich is a modification of checkout_payment_address.php, (again I just unified both checkout_payment_address.php and checkout_shipping_address.php in one file). After changes in address are made succesfully in checkout_address_change.php , the user is redirected to checkout_address.php once again and the selected address is now displayed as current shipping or payment address.

 

So now, when you click the 'next' button in checkout_address.php it links directly to checkout_confirmation.php without going through checkout_payment.php and the whole checkout procedure is done in just two clicks.

 

Everything was working fine in checkout_address.php and checkout_address_change.php but in checkout_confirmation.php:

 

- sometimes i get redirected to checkout_shipping.php (wich i don't use anymore but haven't deleted yet -- just in case... :P )

 

- and sometimes (when not redirected to checkout_shipping.php) Ii get errors where it should display the shipping and payment addresses. This are the errors I get:

 

Warning: htmlspecialchars() expects parameter 1 to be string, array given in /home/ey000143/public_html/prueba/catalog/includes/functions/general.php on line 42

 

Warning: htmlspecialchars() expects parameter 1 to be string, array given in /home/ey000143/public_html/prueba/catalog/includes/functions/general.php on line 42

 

I must specify that the error above is only displayed if the address selected is other than the default customer address, so if both shipping and payment addresses are left untouched at checkout_address.php (both equal to default customer address), then no errors are displayed in checkout_confirmation.php and the addresses are displayed flawlessly.

I took a look at checkout_confirmation.php but there are lots of 'classes' used in it and I don't really understand what do 'shipping' and 'payment' variables do as well as the 'order' array.

 

Any help is appreciated!! :thumbsup:

thanks in advance

Link to comment
Share on other sites

  • 3 weeks later...

Curious how this is going, if you've been able to fix the errors? You should definately post this as a contribution if you get it working correctly I know all of us may be able to benefit from it.

 

Good luck, keep us updated!

Most Valuable OsCommerce Contributions:

Also Purchased (AP) Preselection (cuts this resource hogging query down to nothing) -- Contribution 3294

FedEx Automated Labels -- Contribution 2244

RMA Returns system -- Contribution 1136

Sort Products By Dropdown -- Contribution 4312

Ultimate SEO URLs -- Contribution 2823

Credit Class & Gift Voucher -- Contribution 282

Cross-Sell -- Contribution 5347

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...