Zen Cart Logo
Forums / General Questions / checkout_payment error leads to blank page

checkout_payment error leads to blank page

Locked

Views: 2,414

Results 1 to 6 of 6
This thread is locked. New replies are disabled.
7 Jan 2010, 6:32 PM
#1
dbeecken avatar

dbeecken

New Zenner

Join Date:
Apr 2009
Posts:
26
Plugin Contributions:
0

checkout_payment error leads to blank page

I really do not know what caused this and I only noticed it the other day when doing an order over the phone(although it has not been going on for too long)

But if there is an error on checkout payment(such as bad cvv, wrong credit card number, etc, it does this:

main_page=checkout_payment&payment_error=mg&error=The+credit+card+number+starting+with++was+not+entered+correctly%2C+or+we+do+not+accept+that+kind+of+card.+Please+try+again+or+use+another+credit+card.&cc_expires_month=01&cc_expires_year=10

and it loads a completely blank page. I tried the error loging program and printing out(via configure.php) but there are NO fatal errors(just a bunch of warnings like header already sent)

Also if correct information is included, then it works just fine and allows checkout. Any ideas on where to start

7 Jan 2010, 8:53 PM
#2
rjgonzalez avatar

rjgonzalez

Zen Follower

Join Date:
May 2008
Posts:
155
Plugin Contributions:
0

Re: checkout_payment error leads to blank page

It looks to me that you have not configure the car requested corectly and or the card number is been entered incorrectly (straight numbers no spaces no dashes)

Try to reconfigure your setting on the admin area --> module --> payment --> card desired

7 Jan 2010, 11:17 PM
#3
dbeecken avatar

dbeecken

New Zenner

Join Date:
Apr 2009
Posts:
26
Plugin Contributions:
0

Re: checkout_payment error leads to blank page

Actually, I realized what went wrong, now I just have to compare it. It was from trying to add a hack before(I must now have seen that problem) to allow coupons to be added and have the page reload. I think it has to do with removing the redirect portion on error to the checkout_payment page again(zen_redirect(zen_href_link(FILENAME_CHECKOUT_PAYMENT, '', 'SSL'));
)

I am going to try and find it.

8 Jan 2010, 1:41 AM
#4
dbeecken avatar

dbeecken

New Zenner

Join Date:
Apr 2009
Posts:
26
Plugin Contributions:
0

Re: checkout_payment error leads to blank page

Thought I would add this bit of information if someone has an idea. I am really not sure where to look. I undid the changes I made before with the coupon hack, but it still gives me a blank page.

I loaded the checkout with internet explorer 8 and it gives me an error, http 406

and I found this:

*  Accept: The MIME types accepted by the client. For example, a browser may only accept back types of data (HTML files, GIF files etc.) it knows how to process.
* Accept-Charset: The character sets accepted by the client.
* Accept-Encoding: The data encoding accepted by the client e.g. the file formats it understands.
* Accept-Language: The natural languages (English, German etc.) accepted by the client.
* Accept-Ranges: Whether the client accepts ranges of bytes from the resource i.e. a portion of the resource.

But here I am stuck and really have no idea what to look for. Any suggestions?

10 Jan 2010, 7:15 PM
#5
dbeecken avatar

dbeecken

New Zenner

Join Date:
Apr 2009
Posts:
26
Plugin Contributions:
0

Re: checkout_payment error leads to blank page

Sorry for keep posting I am really at a loss here. I have been going step by step when the error happens, and so far I have figured this.

  1. It happens anytime: "checkout_payment&payment_error=mg&error=ENTER_ERROR_HERE" so if the billing address does not match(notified on the checkout_confirmation page when submit is clicked) or the credit card is wrong type(after submit is clicked on payment page)

  2. So it loads the module /modules/pages/checkout_payment/header_php.php

Thi runs ALL the way through to the end(checked with die) BUT it never once processes this loads:

if (isset($_GET['payment_error']) && is_object(${$_GET['payment_error']}) && ($error = ${$_GET['payment_error']}->get_error())) {
$messageStack->add('checkout_payment', $error['error'], 'error');
}

I checked the inside of the if with die, and it never died inside, and since its loading:checkout_payment&payment_error=mg&error=

should this if statement be run?

ANYHOW, this is the important part, that hopefully someone can help with.

The problem is a 406 error(as noted before) and it happens when the length of the post variable is over 46 characters. So if I shorten the error message, it works fine. The problem is now all can be shortened enough and its not really a solution.

I was shown this post by my host:
http://www.zen-cart.com/forum/showthread.php?t=85858

But only the last one worked and results in no error message going out(bad since the user has no idea what went wrong exactly or that anything went wrong).

Doing this: zen_redirect(zen_href_link(FILENAME_CHECKOUT_PAYMENT, 'error=' . $error, 'SSL', true, false)); as Dr. Byte suggested caused the same error.

Any possible solutions or causes to why this worked before but not anymore?

Thanks to everyone who reads.

26 Apr 2011, 6:20 PM
#6
rickshaw avatar

rickshaw

New Zenner

Join Date:
Apr 2011
Posts:
1
Plugin Contributions:
0

Re: checkout_payment error leads to blank page

I ran into this same issue recently and have found a possibly solution for your problem dbeecken.

That error url you pasted in:
main_page=checkout_payment&payment_error=mg&error=The+credit+card+number+startin g+with++was+not+entered+correctly%2C+or+we+do+not+accept+that+kind+of+card.+Plea se+try+again+or+use+another+credit+card.&cc_expires_month=01&cc_expires_year=10

Should most likely be:

main_page=checkout_payment&payment_error=mg&errormessage=The+credit+card+number+startin g+with++was+not+entered+correctly%2C+or+we+do+not+accept+that+kind+of+card.+Plea se+try+again+or+use+another+credit+card.&cc_expires_month=01&cc_expires_year=10

The distinction to make is that the query string variable "error" should be "errormessage".

So the section:

&error=The+credit+card+number+startin g+with++was+not+entered+correctly%2C+or+we+do+not+accept+that+kind+of+card.+Plea se+try+again+or+use+another+credit+card.

Should be:

&errormessage=The+credit+card+number+startin g+with++was+not+entered+correctly%2C+or+we+do+not+accept+that+kind+of+card.+Plea se+try+again+or+use+another+credit+card.

My issues were with the virtual merchant payment module and that's where I made the correction, hopefully this is something that will help others with the blank payment error page.