Eric
20 Ways to Increase Sales Using Zen Cart
Zen Cart contribs: Simple Google Analytics, Export Shipping Information
My checkout success page is throwing out the following error in the footer:
I have gone back through the installation notes and, as near as I can tell, I have everything configured correctly. I'm collecting data in Analytics, I'm just having this problem with checkout_successWarning: main(includes/templates/patiotoys/checkout_success//google_analytics.php) [function.main]: failed to open stream: No such file or directory in /home/rhutchis/public_html/includes/templates/patiotoys/common/tpl_main_page.php on line 201
Warning: main(includes/templates/patiotoys/checkout_success//google_analytics.php) [function.main]: failed to open stream: No such file or directory in /home/rhutchis/public_html/includes/templates/patiotoys/common/tpl_main_page.php on line 201
Warning: main(includes/templates/patiotoys/checkout_success//google_analytics.php) [function.main]: failed to open stream: No such file or directory in /home/rhutchis/public_html/includes/templates/patiotoys/common/tpl_main_page.php on line 201
Fatal error: main() [function.require]: Failed opening required 'includes/templates/patiotoys/checkout_success//google_analytics.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/rhutchis/public_html/includes/templates/patiotoys/common/tpl_main_page.php on line 201
I'm running ZC 1.3.7 and the body tag for tpl_main_page is:
The included code at the bottom of tpl_main_page is:<body id="<?php echo $body_id . 'Body'; ?>"<?php if($zv_onload !='') echo ' onload="'.$zv_onload.'"'; ?>>
The error tells me that this last bit of code is not picking up the fact that's it needs to look in the templates/patiotoys/google_analytics directory for the file.<?php
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
?>
I have an override directory with templates/patiotoys/checkout_success/tpl_footer.php that I need for my JAM affiliate software, which is likely the culprit.
One solution would be to copy the google_analytics.php file to a directory that the code at the end of tpl_main_page is looking in, but that seems a bit kludgey. Is there an elegant code solution for this?
Thanks,
Roger
Roger,
The footer file should be in the "common" folder as standard zen procedure. It is shared across all pages.
If you need affiliate link tracking only on the checkout_success page (near the footer), then try the following:
1) Copy the line(s) of code you need for the tracking and paste it into the tpl_main_page.php file just above the Google Analytics code. use the following as a guide:
Keep in mind you will need to delete the "tpl_footer.php" file that you included under the "checkout_success" directory as well.<?php
if ($_GET['main_page']=="checkout_success") {
?>
<!--Paste your affiliate code between these comments-->
<!-- End of Affiliate Code -->
<?php }?>
You'll also want to make sure the affiliate link is secure (https:) as the checkout success page is often secure so you wouldn't want to the ssl message box to pop up from the client browser.
Hope that helps.
Last edited by econcepts; 8 Nov 2007 at 03:44 PM. Reason: added info
Eric
20 Ways to Increase Sales Using Zen Cart
Zen Cart contribs: Simple Google Analytics, Export Shipping Information
Hi, I'm trying to install the Simple Google Analytics right now. I've gotten through all the steps up until the install of the SQL patch. I'm in the Admin SQL Query Executer and am not sure how to actually do it. It wouldn't let me just upload the file you provided, so do I copy and paste the whole SQL document into the query frame, then hit send? I'm afraid to mess something up. I would really appreciate some further instructions.
Thanks!
-Becky
Don't forget to take a backup of your database first, just in case :-0
Craig
[FONT=Arial]econcept, why you don’t answer my Emails?[/FONT]
[FONT=Arial]I bought your e-book and it create lots of problem in my web sites?[/FONT]
[FONT=Arial]You should keep some kind of customer support for your product. [/FONT]
[FONT=Arial]For start send me new zip file of the program, as the one I got missing icons, and maybe most likely some files[/FONT]
Motti,
Which e-book are you speaking of? The only e-book I have for purchase is the Google Analytics one, and that shouldn't affect your site at all unless you did not install Google Analytics correctly the first time around?
If you're speaking of the Template Pack I have (it's not an e-book, but the actual template files) for implementing the 20 Ways, then all the files that you need are included in the zip you have. If you are missing anything, or having problems, then it means you installed the contribution incorrectly. That contribution is used on over 50 different sites that I know of without any problems. If the instructions and the 20 Ways book are looked at closely, it works just fine.
Full support for that product is provided at my blog. It would be better to post your questions on it there to benefit all current users of the product.
In addition, you will find answers to many of your questions in both the readme file that came with the pack, in the free 20 Ways e-book itself, and at my blog.
This thread is for the support of the Simple Google Analytics contribution.
Thanks!
Last edited by econcepts; 1 Nov 2007 at 04:13 AM. Reason: added info
Eric
20 Ways to Increase Sales Using Zen Cart
Zen Cart contribs: Simple Google Analytics, Export Shipping Information
[FONT=Times New Roman]Yes I am talking abut the 20 ways template, and yes I know this is not the place to get support for it, but I did try to contact you ( 5 emails 2 days). You should contact me back as you did in the past and give me this link for your blog. [/FONT]
[FONT=Times New Roman]That was not the first mod I bought from you, and most likely not the last. But you got to keep the minimum of support for your stuff[/FONT]
[FONT=Times New Roman][/FONT]
[FONT=Times New Roman]I still need fresh zip file, and yes I am missing icons and almost sure some files too[/FONT]
[FONT=Times New Roman][/FONT]
[FONT=Times New Roman]Thank you[/FONT]