Forums / General Questions / Blank Page When I click add to cart

Blank Page When I click add to cart

Locked

Views: 2,302

Results 1 to 15 of 15
This thread is locked. New replies are disabled.
23 Feb 2009, 3:37 AM
#1
jimmyx avatar

jimmyx

New Zenner

Join Date:
Feb 2009
Posts:
22
Plugin Contributions:
0

Blank Page When I click add to cart

Hello there, Ive been recently playing around with the latest zen cart..

Ive installed a few mods and tonight I just put up one of my first test products... when I click add to cart it just brings me to a blank page: /index.php?main_page=shopping_cart :oops:

I am not sure why its doing this or where I would begin to find out what is causing this etc.

List of mods installed:

reward_point_full_suite_1-21a
monthly_sales_and_tax_summary_report_1-3
graphical_sales_report_v1-02
GoogleSitemapAdmin
enhanced_whos_online_1-0-2
save_for_later_1-0

I think thats all... any help or advice would be much appreciated

23 Feb 2009, 3:42 AM
#2
jimmyx avatar

jimmyx

New Zenner

Join Date:
Feb 2009
Posts:
22
Plugin Contributions:
0

Re: Blank Page When I click add to cart

oh ya I also installed the Optimal Payment API... but I am not sure how thats effecting my cart.

I assume its the SAVE for Later or the Edit Cart (that i didnt complete installing and I think ive removed...)

23 Feb 2009, 4:05 AM
#4
jimmyx avatar

jimmyx

New Zenner

Join Date:
Feb 2009
Posts:
22
Plugin Contributions:
0

Re: Blank Page When I click add to cart

thank you...

I ran this and i got the following:

[22-Feb-2009 20:02:40] PHP Parse error: syntax error, unexpected T_STRING in /home/*******/includes/modules/pages/shopping_cart/header_php.php on line 28

it appears header_php.php was edited or replaced this afternoon.

Now it says line 28.. I am total n00b here do i start at the very top:

<?php /** * shopping_cart header_php.php * * @package page * @copyright Copyright 2003-2007 Zen Cart Development Team * @copyright Portions Copyright 2003 osCommerce * @license <http://w> and count 28 lines down? thanks for your fast replies
23 Feb 2009, 4:13 AM
#5
jimmyx avatar

jimmyx

New Zenner

Join Date:
Feb 2009
Posts:
22
Plugin Contributions:
0

Re: Blank Page When I click add to cart

I am looking through the mods i installed today and yesterday and none that i can find included a header_php.php file... so i am not sure how this got edited / changed....

(i know this sounds dumb but i dont know better) can me installing sql patches effect this? I dont see how SQL modifications would effect the PHP portion of my site... but hey what do i know heheh:blush:

23 Feb 2009, 4:55 AM
#6
jimmyx avatar

jimmyx

New Zenner

Join Date:
Feb 2009
Posts:
22
Plugin Contributions:
0

Re: Blank Page When I click add to cart

I dont know if this is possible, but could i just replace the header_php.php with a stock fresh installed header_php.php from one of my other domains or does it not work like that?

Could I cause more problems down the road?? :lookaroun

23 Feb 2009, 6:04 AM
#7
kellan4459 avatar

kellan4459

New Zenner

Join Date:
Dec 2008
Posts:
79
Plugin Contributions:
0

Re: Blank Page When I click add to cart

yes, you can count down 28 lines. If you haven't changed the header_php.php file you can try replacing it with a fresh one. But it a may not be this file that is the problem. You can post line 28 or a snippet of lines say 25-35 and I will try to help you

23 Feb 2009, 6:23 AM
#8
jimmyx avatar

jimmyx

New Zenner

Join Date:
Feb 2009
Posts:
22
Plugin Contributions:
0

Re: Blank Page When I click add to cart

this would be line 28.... it appears to not be commented out... odd..

Add the following snippet to the file includes/modules/pages/checkout_shipping/header.php. It doesn't really matter where you put it. At the top, just after the header comments is a good place:

ive also replaced this file with a FRESH header from the installation zip and it did fix the problem, i will now attempt to comment this line out in the modified header and see if that solves this problem.

Now I am curious does me applying SQL patches effect other files in zen cart? Basically I am trying to figure out how the file was changed since none of the mods i applied actually contained the /includes/modules/pages/shopping_cart/header_php.php file

23 Feb 2009, 6:26 AM
#9
jimmyx avatar

jimmyx

New Zenner

Join Date:
Feb 2009
Posts:
22
Plugin Contributions:
0

Re: Blank Page When I click add to cart

I commented line 28 out of the modified header and the cart works:clap:, i am just not sure if i should keep the modified header (which is unclear why or how it was modified, but that is now WORKING) or replace it with the WORKING Original header file....

23 Feb 2009, 11:59 PM
#10
kellan4459 avatar

kellan4459

New Zenner

Join Date:
Dec 2008
Posts:
79
Plugin Contributions:
0

Re: Blank Page When I click add to cart

jimmyX:

this would be line 28.... it appears to not be commented out... odd..

Add the following snippet to the file includes/modules/pages/checkout_shipping/header.php. It doesn't really matter where you put it. At the top, just after the header comments is a good place:

ive also replaced this file with a FRESH header from the installation zip and it did fix the problem, i will now attempt to comment this line out in the modified header and see if that solves this problem.

Now I am curious does me applying SQL patches effect other files in zen cart? Basically I am trying to figure out how the file was changed since none of the mods i applied actually contained the /includes/modules/pages/shopping_cart/header_php.php file

Does the file in question have "Add the following snippet" as a line in the code? This should probably not be there and possibly was added by mistake when a mod was added.

I'm not sure I follow you 100%. You mention file includes/modules/pages/checkout_shipping/header.php then later you are asking if SQL would affect files such as /includes/modules/pages/shopping_cart/header_php.php

the answer to the SQL question is no, the SQL should only modify the database tables and fields.

24 Feb 2009, 12:00 AM
#11
kellan4459 avatar

kellan4459

New Zenner

Join Date:
Dec 2008
Posts:
79
Plugin Contributions:
0

Re: Blank Page When I click add to cart

jimmyX:

I commented line 28 out of the modified header and the cart works:clap:, i am just not sure if i should keep the modified header (which is unclear why or how it was modified, but that is now WORKING) or replace it with the WORKING Original header file....

copy and paste the exact line you commented out and I should be able to tell you if what you did is ok

24 Feb 2009, 12:57 AM
#12
jimmyx avatar

jimmyx

New Zenner

Join Date:
Feb 2009
Posts:
22
Plugin Contributions:
0

Re: Blank Page When I click add to cart

Thats what I figured, i just thought id ask you know. I suppose maybe I accidentally updated the header.php file when installing some mods.

But ive since replaced it with the original header.php from a fresh install and were golden.

Thank you for your time and responses.
:D

24 Feb 2009, 12:58 AM
#13
jimmyx avatar

jimmyx

New Zenner

Join Date:
Feb 2009
Posts:
22
Plugin Contributions:
0

Re: Blank Page When I click add to cart

the line in the questionable header.php was exactly as follows:

Add the following snippet to the file includes/modules/pages/checkout_shipping/header.php. It doesn't really matter where you put it. At the top, just after the header comments is a good place:

i have commented it out and everything works fine, ive also just replaced the entire header with a fresh one and well no problems. The cart is functioning well.

24 Feb 2009, 1:54 AM
#14
kellan4459 avatar

kellan4459

New Zenner

Join Date:
Dec 2008
Posts:
79
Plugin Contributions:
0

Re: Blank Page When I click add to cart

what you did was safe, and replacing it works as well, I'm glad you got it working

24 Feb 2009, 1:58 AM
#15
jimmyx avatar

jimmyx

New Zenner

Join Date:
Feb 2009
Posts:
22
Plugin Contributions:
0

Re: Blank Page When I click add to cart

as am i :)

well thanks again for your responses and your initial suggestion of that debug tool. It will be invaluable when(and hopefully if) i come across another issue.

you have a wonderful evening.