Forums / Templates, Stylesheets, Page Layout / How are the product HTML pages generated?

How are the product HTML pages generated?

Results 1 to 16 of 16
22 Sep 2012, 07:35
#1
capncrunch0 avatar

capncrunch0

New Zenner

Join Date:
Aug 2012
Posts:
25
Plugin Contributions:
0

How are the product HTML pages generated?

When a user clicks on a product from a category listing, what files generate the result for the user?
22 Sep 2012, 09:28
#2
picandnix avatar

picandnix

Totally Zenned

Join Date:
Dec 2010
Posts:
1,780
Plugin Contributions:
2

Re: How are the product HTML pages generated?

The product info comes from the database rather than a file, also the files are php and not html. What is it you are wanting to do/know?
22 Sep 2012, 09:39
#3
design75 avatar

design75

Totally Zenned

Join Date:
Dec 2009
Posts:
2,862
Plugin Contributions:
5

Re: How are the product HTML pages generated?

And the product info is build-up through multiple php-files, so like picandnix said. We need a little more information
23 Sep 2012, 03:13
#4
capncrunch0 avatar

capncrunch0

New Zenner

Join Date:
Aug 2012
Posts:
25
Plugin Contributions:
0

Re: How are the product HTML pages generated?

When I click on a category from the category sidebox, a blank page loads instead of the products in that category.
23 Sep 2012, 03:37
#5
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Posts:
21,876
Plugin Contributions:
6

Re: How are the product HTML pages generated?

Blank as in completely empty, or as in center column empty? You likely have a PHP error; see the tutorials or the wiki under "troubleshooting". Also look in your /cache/ folder in your Zen Cart root and post the latest myDebug file.
23 Sep 2012, 04:34
#6
capncrunch0 avatar

capncrunch0

New Zenner

Join Date:
Aug 2012
Posts:
25
Plugin Contributions:
0

Re: How are the product HTML pages generated?

Center column empty.

myDEBUG-1348339549-197239.log:

[22-Sep-2012 12:45:49] PHP Warning: include_once(includes/languages/english.php) [<a href='function.include-once'>function.include-once</a>]: failed to open stream: No such file or directory in /home/pnaples9/public_html/spa/includes/init_includes/init_templates.php on line 72
[22-Sep-2012 12:45:49] PHP Warning: include_once() [<a href='function.include'>function.include</a>]: Failed opening 'includes/languages/english.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/pnaples9/public_html/spa/includes/init_includes/init_templates.php on line 72
23 Sep 2012, 04:45
#7
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,506
Plugin Contributions:
173

Re: How are the product HTML pages generated?

capncrunch0:

[22-Sep-2012 12:45:49] PHP Warning: include_once(includes/languages/english.php) [function.include-once]: failed to open stream: No such file or directory in ...


The error message is telling you that your english.php file is missing.
23 Sep 2012, 04:48
#8
capncrunch0 avatar

capncrunch0

New Zenner

Join Date:
Aug 2012
Posts:
25
Plugin Contributions:
0

Re: How are the product HTML pages generated?

Thank you.

The latest debug file when I tested the problem:

[22-Sep-2012 22:30:34] PHP Warning: include_once(includes/languages/english.php) [<a href='function.include-once'>function.include-once</a>]: failed to open stream: No such file or directory in /home/pnaples9/public_html/spa/includes/init_includes/init_templates.php on line 72
[22-Sep-2012 22:30:34] PHP Warning: include_once() [<a href='function.include'>function.include</a>]: Failed opening 'includes/languages/english.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/pnaples9/public_html/spa/includes/init_includes/init_templates.php on line 72
[22-Sep-2012 22:30:34] PHP Parse error: syntax error, unexpected T_REQUIRE in /home/pnaples9/public_html/spa/includes/templates/custom/templates/tpl_product_info_display.php on line 1
23 Sep 2012, 06:33
#9
capncrunch0 avatar

capncrunch0

New Zenner

Join Date:
Aug 2012
Posts:
25
Plugin Contributions:
0

Re: How are the product HTML pages generated?

DrByte:

The error message is telling you that your english.php file is missing.


I commented out the code on line 72 because I don't have a custom english.php file. Now only the parse error shows.
23 Sep 2012, 06:35
#10
picandnix avatar

picandnix

Totally Zenned

Join Date:
Dec 2010
Posts:
1,780
Plugin Contributions:
2

Re: How are the product HTML pages generated?

Are you attempting to add a mod? If so which one, and are you merging files or just overwriting.
23 Sep 2012, 06:49
#11
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Posts:
21,876
Plugin Contributions:
6

Re: How are the product HTML pages generated?

I commented out the code on line 72 because I don't have a custom english.php file.
If you don't have a custom version, then the code will look for the stock version (which is what the error message says is missing). You can't disable some code and expect to have the rest still function correctly, unless you *know* that nothing else depends on the disabled code.
23 Sep 2012, 07:00
#12
capncrunch0 avatar

capncrunch0

New Zenner

Join Date:
Aug 2012
Posts:
25
Plugin Contributions:
0

Re: How are the product HTML pages generated?

It's strange because the english.php isn't missing. Plus the comments in the php file say that you may have to disable the code.
23 Sep 2012, 07:43
#13
design75 avatar

design75

Totally Zenned

Join Date:
Dec 2009
Posts:
2,862
Plugin Contributions:
5

Re: How are the product HTML pages generated?

I think you should start by solving this problem first

[22-Sep-2012 22:30:34] PHP Parse error: syntax error, unexpected T_REQUIRE in /home/pnaples9/public_html/spa/includes/templates/custom/templates/tpl_product_info_display.php on line 1


chances are it will solve the other problem to. Like picandnix asked, were you installing any mods? Which file is the require statement asking for?
23 Sep 2012, 07:56
#14
capncrunch0 avatar

capncrunch0

New Zenner

Join Date:
Aug 2012
Posts:
25
Plugin Contributions:
0

Re: How are the product HTML pages generated?

I am not installing any mods; I am using the file override system for custom templates. Also I seemed to have found the culprit. The tpl_product_info.php file code had been transformed to fit all on one line. Sections with comments got intermingled with actual code, etc., etc., ...
Let you know...
23 Sep 2012, 12:48
#15
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,506
Plugin Contributions:
173

Re: How are the product HTML pages generated?

capncrunch0:

I commented out the code on line 72 because I don't have a custom english.php file. Now only the parse error shows.


That is the *wrong* thing to do. Line 72 is important. It is not your problem; it is only "the messenger".
You'll need to undo that commenting.

The error message is telling you that it's looking for the MAIN english.php file, not a "custom" one.

First thing I'd do right now is go back and check all your files to make sure all the original files ARE actually present on your server. Anything you deleted should be put back. Anything that failed to upload correctly needs to be fixed.
Then I'd also check all your files to undo anything you changed while "troubleshooting". Making guesses at changing any original core files has probably taken you in the wrong direction.
Then look at all the files you've added (whether yourself or via a plugin) and determine what errors you've made in those files.
25 Sep 2012, 07:34
#16
capncrunch0 avatar

capncrunch0

New Zenner

Join Date:
Aug 2012
Posts:
25
Plugin Contributions:
0

Re: How are the product HTML pages generated?

Yeah, I was using a tpl_product_info_display.php from a previous customized version of Zen Cart. I still don't know how the code got put into one horizontal line though. I deleted the file from the override folder (realizing that there was nothing custom about it). The links load the products now.

Thanks for the advice & helping me walk through the troubleshooting. Thank you for the tips also.