-
Simple Google Analytics - Support
I have simplified the Google Analytics integration process and am realeasing it for all to enjoy. Follow the readme directions for instalation.
There are only 2 files to be uploaded. One of which is one line and utilizes the $zv_onload variable and is not neccasary if you make an extra addition to your template and is explained in the readme. Also an sql patch needs to be installed.
Available:
http://www.zen-cart.com/index.php?ma...roducts_id=412
Enjoy
-
Re: Simple Google Analytics - Support
Will this track transaction information too? Or just the success of a sale?
I thought with analytics you can track transaction details and report on it.
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
zwenthe
Will this track transaction information too? Or just the success of a sale?
I thought with analytics you can track transaction details and report on it.
Yes this will allow Google Analytics to track your transactions and entrance points, search queries, etc. So much info you won't know what to do with it.
-
Re: Simple Google Analytics - Support
I assume this is for ver 1.3.6, will it also work for ver 1.2.7?
-
Re: Simple Google Analytics - Support
This should work without any problems in 1.2.7 but I have not tested it. Follow the readme and if you have any issues I am happy to help. It really is a pretty simple mod.
-
Re: Simple Google Analytics - Support
i'm on step 2
2. Make sure your body tag in includes/templates/[your_template] includes this code (if not see trouble shooting below it is not neccassary but an addition to your template needs to be made):
<body id="<?php echo $body_id . 'Body'; ?>"<?php if($zv_onload !='') echo ' onload="'.$zv_onload.'"'; ?>>
which file is this?
step 3 wasn't a problem, and 4 and 5 look like they will be easy enough once i get step 2 done
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
MB1
i'm on step 2
2. Make sure your body tag in includes/templates/[your_template] includes this code (if not see trouble shooting below it is not neccassary but an addition to your template needs to be made):
<body id="<?php echo $body_id . 'Body'; ?>"<?php if($zv_onload !='') echo ' onload="'.$zv_onload.'"'; ?>>
which file is this?
step 3 wasn't a problem, and 4 and 5 look like they will be easy enough once i get step 2 done
By default this is in includes/templates/[your_template]/common/tpl_main_page.php
but could be located in includes/templates/[your_template]/common/tpl_header.php
as well, depends on how your site has been templated.
-
Re: Simple Google Analytics - Support
sweet i'll see if i can get past step 2 now.
also i signed up to https://www.google.com/analytics/ and they say i should put in a code on every page i want to track will this module take care of all that stuff?
-
Re: Simple Google Analytics - Support
well it says it's working but only after i install the code from the site
Code:
<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "UA-XXXXXXXX";
urchinTracker();
</script>
btw i placed that code at the bottom of the includes/templates/[your_template]/common/tpl_main_page.php page just after the code from this module and before the </body>
is there anything else i should do?
-
Re: Simple Google Analytics - Support
Ok MB1 this is the code that should be at the bottom of your template (includes/templates/yourtemplate/common/tpl_main_page.php) just before the </body> tag (the code you posted is just the standard code from google and is included in the google_analytics.php file which you should have uploaded to your server in a folder named 'google_analytics'):
PHP Code:
<?php
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
?>
So the code above is all that should be at the bottom of your template.... is it?
This module, in theory, should take care of the rest. You will have to enter your google analytics account number in your admin->configuration->google analytics configuration.
Remove the code provided by google and replace with the above Follow step 3. Then reload your site and view the source and at the bottom you should see the proper tracking code if everything is functioning properly. Let me know
-
Re: Simple Google Analytics - Support
Waiting for Data so it must be working just fine thank you
-
Re: Simple Google Analytics - Support
yep congrats it should be working now if it says waiting for data...do one more thing go to a secure page (checkout) and make sure you do not get any warnings. Report back in a few days and let me know how it is working for you and if it is tracking orders and everything.
-
Re: Simple Google Analytics - Support
i logged on and went to the check out short of comfirming an order no warnings. is that what you wanted me to do?
-
Re: Simple Google Analytics - Support
sorry to burst your bubble.. but a little before you released this mod a_berezin included a "variant_include" version of his mod.. which is basically doing the same thing as this (no javascript calling other javascript.. basically just puts it at the bottom of the template and checks ssl vs non-ssl). Not sure if you knew about this...
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
getyourgameshere.com
sorry to burst your bubble.. but a little before you released this mod a_berezin included a "variant_include" version of his mod.. which is basically doing the same thing as this (no javascript calling other javascript.. basically just puts it at the bottom of the template and checks ssl vs non-ssl). Not sure if you knew about this...
Thanks for the heads up I did not know he had released a new version I just wanted to make the process easier for everyone. I am here to help any that want to give this version a try.
Cuda
-
Re: Simple Google Analytics - Support
Yes I just installed Andrew's new version "variant_javascript" on Zen Cart 1.36 and it works good. Easy install. Just two files to upload, no editing, merges or overrides required. See the original GA mod support thread for info.
Woody
-
Re: Simple Google Analytics - Support
Hey guys- There are 2 different versions. So? They both work. Please post your comments about Andrew's version in the other thread.
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
Kim
Hey guys- There are 2 different versions. So? They both work. Please post your comments about Andrew's version in the other thread.
Huh? I certainly wasn't dissing Cuda's version/contribution. Rather I was stating another version was available and working, just as cuda had posted in the "other" mods support thread. Frankly I don't understand what the big deal is in doing so. Happy Holidays!
-
Re: Simple Google Analytics - Support
-
Re: Simple Google Analytics - Support
I have this installed on ver 1.2.7, it records the visits and goal conversions, but not the transaction and order value. Any ideas where I am going wrong?
-
Re: Simple Google Analytics - Support
Hi,
I installed this on v1.37, went through the readme and followed all the instructions yet on the google analytic site, I'm still getting the message:
Tracking Not Installed (Last checked: 2007-01-28 7:13 PM PST.)
The Google Analytics tracking code has not been detected on your website's home page. For Analytics to function, you or your web administrator must add the code to each page of your website.
Could I have missed something or does it take a while for it to find the code when I have it re-check?
thank you,
betty
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
bettysue
Hi,
I installed this on v1.37, went through the readme and followed all the instructions yet on the google analytic site, I'm still getting the message:
Tracking Not Installed (Last checked: 2007-01-28 7:13 PM PST.)
The Google Analytics tracking code has not been detected on your website's home page. For Analytics to function, you or your web administrator must add the code to each page of your website.
Could I have missed something or does it take a while for it to find the code when I have it re-check?
thank you,
betty
Betty Did you go into the admin and go to configuration->Google analytics configuration and enter your Analytics account number? it should not be UA-XXXXXX-1 it should be your actual account number from google.
Also give me a url and I will take a look.
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
Nellie
I have this installed on ver 1.2.7, it records the visits and goal conversions, but not the transaction and order value. Any ideas where I am going wrong?
Nellie - This module has not been tested on 1.2.7 so not sure the problem but lets fix the problem. can you give me a url so I can take a look
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
cuda
Betty Did you go into the admin and go to configuration->Google analytics configuration and enter your Analytics account number? it should not be UA-XXXXXX-1 it should be your actual account number from google.
Also give me a url and I will take a look.
Hi,
Yes I did put the account number in admin. The only thing I didn't put anything in was the affiliate entry as I didn't know what it was for.
http://www.buysoul.com
thank you,
betty
-
Re: Simple Google Analytics - Support
Thanks Cuda, have a look at www.fromhome.co.za.
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
bettysue
Hi,
Yes I did put the account number in admin. The only thing I didn't put anything in was the affiliate entry as I didn't know what it was for.
http://www.buysoul.com
thank you,
betty
When I go and view the source of your home page I get this code at the bottom:
Code:
<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "UA-XXXXXX-X";
urchinTracker();
</script>
The XXXX are there so that indicates to me that your database does not have the account number in it. Also make sure just before the </body> tag in your home page template because you may have just the code above there and that could be your problem:
PHP Code:
<?php
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
?>
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
cuda
The XXXX are there so that indicates to me that your database does not have the account number in it. Also make sure just before the </body> tag in your home page template because you may have just the code above there and that could be your problem:
PHP Code:
<?php
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
?>
The UH number is in the config in admin, I didn't see in the instructions that I had to enter it elsewhere.
Plus I did enter the code just before the end body tag.
The last few lines of my templates/custom/common/tpl_main_page.php are:
Code:
<!--eof- banner #6 display -->
</div>
<?php
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
?>
</body>
I also made sure that my body statement had the $zv_onload statement in it.
Code:
?>
<body id="<?php echo $body_id . 'Body'; ?>"<?php if($zv_onload !='') echo ' onload="'.$zv_onload.'"'; ?>>
<?php
What did I miss?
betty
-
Re: Simple Google Analytics - Support
I just went back to Google Analytics and it says "Receiving Data" so it must be finding it now?
I don't know what the message below it means, there is a yellow explamation mark and says "Conversion Goals (0)" .
thank you,
betty
-
Re: Simple Google Analytics - Support
Hey Betty, you need to setup goals in Google's control panel, edit the settings of your website profile and complete the Conversion goals and funnel section.
-
Re: Simple Google Analytics - Support
I have been trying to track down this error that came up tonight when I was doing an order to see if everything worked ok (please note the double // in path):
Code:
<!--bof- parse time display -->
<!--eof- parse time display -->
<!--bof- banner #6 display -->
<!--eof- banner #6 display -->
</div>
<br />
<b>Warning</b>: main(includes/templates/custom/checkout_success//google_analytics.php) [<a href='function.main'>function.main</a>]: failed to open stream: No such file or directory in <b>/path/removed/public_html/store/includes/templates/custom/common/tpl_main_page.php</b> on line <b>184</b><br />
<br />
<b>Warning</b>: main(includes/templates/custom/checkout_success//google_analytics.php) [<a href='function.main'>function.main</a>]: failed to open stream: No such file or directory in <b>/path/removed/public_html/store/includes/templates/custom/common/tpl_main_page.php</b> on line <b>184</b><br />
<br />
<b>Fatal error</b>: main() [<a href='function.require'>function.require</a>]: Failed opening required 'includes/templates/custom/checkout_success//google_analytics.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in <b>/path/removed/public_html/store/includes/templates/custom/common/tpl_main_page.php</b> on line <b>184</b><br />
betty
-
Re: Simple Google Analytics - Support
Hi,
I've installed Simple Google Analytics, and wanted to ask a quick question about a possible modification. My store is on a subdomain of my main site. Google says that in order to track subdomains in the same profile as the main domain, a line of code needs to be added to the normal Analytics call.
The line that needs to be added is the one in bold. (This is the code as copied right off Google's help page)
Code:
<script>
_uacct="UA-xxxx-x";
_udn="mystore.com";
urchinTracker();
</script>
So, do I just add this line to the google_analytics.php file like so:
Code:
<script type="text/javascript">
_uacct = "' . GOOGLE_ANALYTICS_UACCT . '";
_udn="mystore.com";
urchinTracker();
</script>';
(with my domain in place of mystore.com)
Should that work? Thanks!
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
peggyc
So, do I just add this line to the google_analytics.php file
Yes, that's the right place to add it.
What happens when you do ?
-
Re: Simple Google Analytics - Support
Dr. Byte,
Any idea why I'm getting the double // in my error message above? I checked the google analytics file and it just has one / in it.
thank you,
betty
-
Re: Simple Google Analytics - Support
post a copy of your /store/includes/templates/custom/common/tpl_main_page.php file for review.
-
Re: Simple Google Analytics - Support
Here is my complete tpl_main_page.php from my includes/templates/custom/common directory:
Code:
<?php
/**
* Common Template - tpl_main_page.php
*
* Governs the overall layout of an entire page<br />
* Normally consisting of a header, left side column. center column. right side column and footer<br />
* For customizing, this file can be copied to /templates/your_template_dir/pagename<br />
* example: to override the privacy page<br />
* - make a directory /templates/my_template/privacy<br />
* - copy /templates/templates_defaults/common/tpl_main_page.php to /templates/my_template/privacy/tpl_main_page.php<br />
* <br />
* to override the global settings and turn off columns un-comment the lines below for the correct column to turn off<br />
* to turn off the header and/or footer uncomment the lines below<br />
* Note: header can be disabled in the tpl_header.php<br />
* Note: footer can be disabled in the tpl_footer.php<br />
* <br />
* $flag_disable_header = true;<br />
* $flag_disable_left = true;<br />
* $flag_disable_right = true;<br />
* $flag_disable_footer = true;<br />
* <br />
* // example to not display right column on main page when Always Show Categories is OFF<br />
* <br />
* if ($current_page_base == 'index' and $cPath == '') {<br />
* $flag_disable_right = true;<br />
* }<br />
* <br />
* example to not display right column on main page when Always Show Categories is ON and set to categories_id 3<br />
* <br />
* if ($current_page_base == 'index' and $cPath == '' or $cPath == '3') {<br />
* $flag_disable_right = true;<br />
* }<br />
*
* @package templateSystem
* @copyright Copyright 2003-2006 Zen Cart Development Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
* @version $Id: tpl_main_page.php 3856 2006-06-29 02:26:33Z drbyte $
*/
// the following IF statement can be duplicated/modified as needed to set additional flags
if (in_array($current_page_base,explode(",",'list_pages_to_skip_all_right_sideboxes_on_here,separated_by_commas,and_no_spaces')) ) {
$flag_disable_right = true;
}
$header_template = 'tpl_header.php';
$footer_template = 'tpl_footer.php';
$left_column_file = 'column_left.php';
$right_column_file = 'column_right.php';
$body_id = str_replace('_', '', $_GET['main_page']);
?>
<body id="<?php echo $body_id . 'Body'; ?>"<?php if($zv_onload !='') echo ' onload="'.$zv_onload.'"'; ?>>
<?php
if (SHOW_BANNERS_GROUP_SET1 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET1)) {
if ($banner->RecordCount() > 0) {
?>
<div id="bannerOne" class="banners"><?php echo zen_display_banner('static', $banner); ?></div>
<?php
}
}
?>
<div id="mainWrapper" align="center">
<?php
/**
* prepares and displays header output
*
*/
require($template->get_template_dir('tpl_header.php',DIR_WS_TEMPLATE, $current_page_base,'common'). '/tpl_header.php');?>
<table width="100%" border="0" cellspacing="0" cellpadding="0" id="contentMainWrapper">
<tr>
<?php
if (COLUMN_LEFT_STATUS == 0 or (CUSTOMERS_APPROVAL == '1' and $_SESSION['customer_id'] == '')) {
// global disable of column_left
$flag_disable_left = true;
}
if (!isset($flag_disable_left) || !$flag_disable_left) {
?>
<td id="navColumnOne" class="columnLeft" style="width: <?php echo COLUMN_WIDTH_LEFT; ?>">
<?php
/**
* prepares and displays left column sideboxes
*
*/
?>
<div id="navColumnOneWrapper" style="width: <?php echo BOX_WIDTH_LEFT; ?>"><?php require(DIR_WS_MODULES . zen_get_module_directory('column_left.php')); ?></div></td>
<?php
}
?>
<td valign="top">
<!-- bof breadcrumb -->
<?php if (DEFINE_BREADCRUMB_STATUS == '1') { ?>
<div id="navBreadCrumb"><?php echo $breadcrumb->trail(BREAD_CRUMBS_SEPARATOR); ?></div>
<?php } ?>
<!-- eof breadcrumb -->
<?php
if (SHOW_BANNERS_GROUP_SET3 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET3)) {
if ($banner->RecordCount() > 0) {
?>
<div id="bannerThree" class="banners"><?php echo zen_display_banner('static', $banner); ?></div>
<?php
}
}
?>
<!-- bof upload alerts -->
<?php if ($messageStack->size('upload') > 0) echo $messageStack->output('upload'); ?>
<!-- eof upload alerts -->
<?php
/**
* prepares and displays center column
*
*/
require($body_code); ?>
<?php
if (SHOW_BANNERS_GROUP_SET4 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET4)) {
if ($banner->RecordCount() > 0) {
?>
<div id="bannerFour" class="banners">
<div align="center">
<?php echo zen_display_banner('static', $banner); ?></div></div>
<?php
}
}
?></td>
<?php
if (COLUMN_RIGHT_STATUS == 0 or (CUSTOMERS_APPROVAL == '1' and $_SESSION['customer_id'] == '')) {
// global disable of column_right
$flag_disable_right = true;
}
if (!isset($flag_disable_right) || !$flag_disable_right) {
?>
<td id="navColumnTwo" class="columnRight" style="width: <?php echo COLUMN_WIDTH_RIGHT; ?>">
<?php
/**
* prepares and displays right column sideboxes
*
*/
?>
<div id="navColumnTwoWrapper" style="width: <?php echo BOX_WIDTH_RIGHT; ?>"><?php require(DIR_WS_MODULES . zen_get_module_directory('column_right.php')); ?></div></td>
<?php
}
?>
</tr>
</table>
<div align="center">
<?php
/**
* prepares and displays footer output
*
*/
require($template->get_template_dir('tpl_footer.php',DIR_WS_TEMPLATE, $current_page_base,'common'). '/tpl_footer.php');?>
</div>
<!--bof- parse time display -->
<?php
if (DISPLAY_PAGE_PARSE_TIME == 'true') {
?>
<div class="smallText center">Parse Time: <?php echo $parse_time; ?> - Number of Queries: <?php echo $db->queryCount(); ?> - Query Time: <?php echo $db->queryTime(); ?></div>
<?php
}
?>
<!--eof- parse time display -->
<!--bof- banner #6 display -->
<?php
if (SHOW_BANNERS_GROUP_SET6 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET6)) {
if ($banner->RecordCount() > 0) {
?>
<div id="bannerSix" class="banners"><?php echo zen_display_banner('static', $banner); ?></div>
<?php
}
}
?>
<!--eof- banner #6 display -->
</div>
<?php
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
?>
</body>
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
DrByte
Yes, that's the right place to add it.
What happens when you do ?
Judging by View Source, it appears to have worked!
Thanks, Dr. B. -- Zen Cart is my first experience with PHP, so I wanted some reassurance before monkeying around with this too much. :smile:
-
Re: Simple Google Analytics - Support
bettysue,
Since you're apparently only running this for checkout_success, then perhaps you need to change the logic to check and be sure the file exists.
Try changing this:
Code:
<?php
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
?>
to this:
Code:
<?php
if (file_exists($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php')) {
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
}
?>
-
Re: Simple Google Analytics - Support
Is that advice for me or the other poster Dr. Byte?
If it's for me, that is the only place the mod said to put the code. Should it be elsewhere also?
betty
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
bettysue
Is that advice for me or the other poster Dr. Byte?
If it's for me, that is the only place the mod said to put the code. Should it be elsewhere also?
betty
Yes, that was for you.
I only suggest the fix for that particular location. Haven't considered other places.
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
DrByte
Yes, that was for you.
I only suggest the fix for that particular location. Haven't considered other places.
I actually got the identical error bettysue described in doing test runs through my site. I plugged your fix in on tpl_main_page.php and what it does now is just not call for the google analytics code on checkout_success (although the script appears to show up just fine on every other page in the site, including the other pages in the checkout process.)
Obviously it's preferable to have no error code show up, so I thank you for the fix! But I am curious as to what it is about checkout_success that causes the error in the first place, when it didn't occur on any other page in the site.
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
bettysue
Dr. Byte,
Any idea why I'm getting the double // in my error message above? I checked the google analytics file and it just has one / in it.
thank you,
betty
betty the double forward slashes may be a server setting or it may be a change to the get_template_dir() function in 1.3.7 either way it should not matter. To make it look nicer remove the '/' before 'google_analytics.php' from this line in your template:
PHP Code:
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
To make it look like this
PHP Code:
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . 'google_analytics.php');
And if you used dr bytes suggestion to check if the file exists change that line too.
I still do not see your google account number showing up in the tracking code on your home page so there is another issue.....But not sure how the XXXX could posible show up unless you have it entered in your dB or hard coded somewhere. You sure your account number is in your admin....I just don't see any other way for this code to spit our xxxxx unless that is the number in your dB and make sure it is on your live site and not a local test site.
Sorry for the delay in response had some car troubles and been shopping around the last couple days for a new one.
cuda
-
Re: Simple Google Analytics - Support
I have everything installed and setup on our site www.threeknightsgaming.com but when I hit google it says it can't find the files needed. I have this on
my /public_html/includes/templates/template_default/common/tpl_main_page.php
<?php
/**
* Common Template - tpl_main_page.php
*
* Governs the overall layout of an entire page<br />
* Normally consisting of a header, left side column. center column. right side column and footer<br />
* For customizing, this file can be copied to /templates/your_template_dir/pagename<br />
* example: to override the privacy page<br />
* - make a directory /templates/my_template/privacy<br />
* - copy /templates/templates_defaults/common/tpl_main_page.php to /templates/my_template/privacy/tpl_main_page.php<br />
* <br />
* to override the global settings and turn off columns un-comment the lines below for the correct column to turn off<br />
* to turn off the header and/or footer uncomment the lines below<br />
* Note: header can be disabled in the tpl_header.php<br />
* Note: footer can be disabled in the tpl_footer.php<br />
* <br />
* $flag_disable_header = true;<br />
* $flag_disable_left = true;<br />
* $flag_disable_right = true;<br />
* $flag_disable_footer = true;<br />
* <br />
* // example to not display right column on main page when Always Show Categories is OFF<br />
* <br />
* if ($current_page_base == 'index' and $cPath == '') {<br />
* $flag_disable_right = true;<br />
* }<br />
* <br />
* example to not display right column on main page when Always Show Categories is ON and set to categories_id 3<br />
* <br />
* if ($current_page_base == 'index' and $cPath == '' or $cPath == '3') {<br />
* $flag_disable_right = true;<br />
* }<br />
*
* @package templateSystem
* @copyright Copyright 2003-2006 Zen Cart Development Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
* @version $Id: tpl_main_page.php 3856 2006-06-29 02:26:33Z drbyte $
*/
// the following IF statement can be duplicated/modified as needed to set additional flags
if (in_array($current_page_base,explode(",",'list_pages_to_skip_all_right_sideboxes _on_here,separated_by_commas,and_no_spaces')) ) {
$flag_disable_right = true;
}
$header_template = 'tpl_header.php';
$footer_template = 'tpl_footer.php';
$left_column_file = 'column_left.php';
$right_column_file = 'column_right.php';
$body_id = str_replace('_', '', $_GET['main_page']);
?>
<body id="<?php echo $body_id . 'Body'; ?>"<?php if($zv_onload !='') echo ' onload="'.$zv_onload.'"'; ?>>
<?php
if (SHOW_BANNERS_GROUP_SET1 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET1)) {
if ($banner->RecordCount() > 0) {
?>
<div id="bannerOne" class="banners"><?php echo zen_display_banner('static', $banner); ?></div>
<?php
}
}
?>
<div id="mainWrapper">
<?php
/**
* prepares and displays header output
*
*/
require($template->get_template_dir('tpl_header.php',DIR_WS_TEMPLATE, $current_page_base,'common'). '/tpl_header.php');?>
<table width="100%" border="0" cellspacing="0" cellpadding="0" id="contentMainWrapper">
<tr>
<?php
if (COLUMN_LEFT_STATUS == 0 or (CUSTOMERS_APPROVAL == '1' and $_SESSION['customer_id'] == '')) {
// global disable of column_left
$flag_disable_left = true;
}
if (!isset($flag_disable_left) || !$flag_disable_left) {
?>
<td id="navColumnOne" class="columnLeft" style="width: <?php echo COLUMN_WIDTH_LEFT; ?>">
<?php
/**
* prepares and displays left column sideboxes
*
*/
?>
<div id="navColumnOneWrapper" style="width: <?php echo BOX_WIDTH_LEFT; ?>"><?php require(DIR_WS_MODULES . zen_get_module_directory('column_left.php')); ?></div></td>
<?php
}
?>
<td valign="top">
<!-- bof breadcrumb -->
<?php if (DEFINE_BREADCRUMB_STATUS == '1') { ?>
<div id="navBreadCrumb"><?php echo $breadcrumb->trail(BREAD_CRUMBS_SEPARATOR); ?></div>
<?php } ?>
<!-- eof breadcrumb -->
<?php
if (SHOW_BANNERS_GROUP_SET3 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET3)) {
if ($banner->RecordCount() > 0) {
?>
<div id="bannerThree" class="banners"><?php echo zen_display_banner('static', $banner); ?></div>
<?php
}
}
?>
<!-- bof upload alerts -->
<?php if ($messageStack->size('upload') > 0) echo $messageStack->output('upload'); ?>
<!-- eof upload alerts -->
<?php
/**
* prepares and displays center column
*
*/
require($body_code); ?>
<?php
if (SHOW_BANNERS_GROUP_SET4 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET4)) {
if ($banner->RecordCount() > 0) {
?>
<div id="bannerFour" class="banners"><?php echo zen_display_banner('static', $banner); ?></div>
<?php
}
}
?></td>
<?php
if (COLUMN_RIGHT_STATUS == 0 or (CUSTOMERS_APPROVAL == '1' and $_SESSION['customer_id'] == '')) {
// global disable of column_right
$flag_disable_right = true;
}
if (!isset($flag_disable_right) || !$flag_disable_right) {
?>
<td id="navColumnTwo" class="columnRight" style="width: <?php echo COLUMN_WIDTH_RIGHT; ?>">
<?php
/**
* prepares and displays right column sideboxes
*
*/
?>
<div id="navColumnTwoWrapper" style="width: <?php echo BOX_WIDTH_RIGHT; ?>"><?php require(DIR_WS_MODULES . zen_get_module_directory('column_right.php')); ?></div></td>
<?php
}
?>
</tr>
</table>
<?php
/**
* prepares and displays footer output
*
*/
require($template->get_template_dir('tpl_footer.php',DIR_WS_TEMPLATE, $current_page_base,'common'). '/tpl_footer.php');?>
</div>
<!--bof- parse time display -->
<?php
if (DISPLAY_PAGE_PARSE_TIME == 'true') {
?>
<div class="smallText center">Parse Time: <?php echo $parse_time; ?> - Number of Queries: <?php echo $db->queryCount(); ?> - Query Time: <?php echo $db->queryTime(); ?></div>
<?php
}
?>
<!--eof- parse time display -->
<!--bof- banner #6 display -->
<?php
if (SHOW_BANNERS_GROUP_SET6 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET6)) {
if ($banner->RecordCount() > 0) {
?>
<div id="bannerSix" class="banners"><?php echo zen_display_banner('static', $banner); ?></div>
<?php
}
}
?>
<!--eof- banner #6 display -->
<?php
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
?>
</body>
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
peggyc
I actually got the identical error bettysue described in doing test runs through my site. I plugged your fix in on tpl_main_page.php and what it does now is just not call for the google analytics code on checkout_success (although the script appears to show up just fine on every other page in the site, including the other pages in the checkout process.)
Obviously it's preferable to have no error code show up, so I thank you for the fix! But I am curious as to what it is about checkout_success that causes the error in the first place, when it didn't occur on any other page in the site.
I had another error issue that I had posted in a different thread which is about the JRox affiliate manager.
The reply there indicated that Jrox may not work with express pay. Although after I installed Dr. Bytes paypal update I didn't get those error messages any more.
betty
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
Nellie
I have this installed on ver 1.2.7, it records the visits and goal conversions, but not the transaction and order value. Any ideas where I am going wrong?
Hey nellie I am back to help....
ok first things first view the source of your home page:
Code:
<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "UA-861757-5";
urchinTracker();
</script><script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "UA-861757-5";
urchinTracker();
</script>
Notice the double up of tracking code. This is probably due to you adding a hard coded version as google suggests and using the one line include from this module. Remove the hard coded line from your template all you need is this line (modified with dr bytes suggestion to check the file is actually there):
PHP Code:
<?php
if (file_exists($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php'))
{
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
}
?>
This maybe the issue as to why you are not getting checkout tracking it may also have to do with paygate. What is the test credit card number for paygate so I can make a fake purchase and check the code?
cuda
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
bettysue
I had another error issue that I had posted in a different thread which is about the JRox affiliate manager.
The reply there indicated that Jrox may not work with express pay. Although after I installed Dr. Bytes paypal update I didn't get those error messages any more.
betty
Hmm, I'm using JRox too -- I wonder if there's some incompatibilty there causing this Analytics problem?
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
threekni
I have everything installed and setup on our site
www.threeknightsgaming.com but when I hit google it says it can't find the files needed. I have this on
my /public_html/includes/templates/template_default/common/tpl_main_page.php
Your code looks fine did you just instal it? In your google analytics account on the first page does your status column have a little green check next to recieving data? Where do you see this files are missing message?
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
cuda
betty the double forward slashes may be a server setting or it may be a change to the get_template_dir() function in 1.3.7 either way it should not matter. To make it look nicer remove the '/' before 'google_analytics.php' from this line in your template:
PHP Code:
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
To make it look like this
PHP Code:
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . 'google_analytics.php');
And if you used dr bytes suggestion to check if the file exists change that line too.
I still do not see your google account number showing up in the tracking code on your home page so there is another issue.....But not sure how the XXXX could posible show up unless you have it entered in your dB or hard coded somewhere. You sure your account number is in your admin....I just don't see any other way for this code to spit our xxxxx unless that is the number in your dB and make sure it is on your live site and not a local test site.
Sorry for the delay in response had some car troubles and been shopping around the last couple days for a new one.
cuda
Ok, I've removed the / in the path and will see if that fixes it or if it errors out again.
As far as my analytics id, I feel like I'm in the twilight zone :blink: I checked in admin and it was back to the default listing with the X's in it again. This will make the third time I've entered my UH number in admin.
If it comes up missing again, then I definitely have more of a problem then a / !
thank you for the fix info and the fact my number was missing again.
betty
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
bettysue
Ok,
If it comes up missing again, then I definitely have more of a problem then a / !
thank you for the fix info and the fact my number was missing again.
betty
Ok you have no code showing on your home page now. Put that slash back and upload the file. Then let me know so I can check it.
cuda
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
cuda
Your code looks fine did you just instal it? In your google analytics account on the first page does your status column have a little green check next to recieving data? Where do you see this files are missing message?
No it says status unverified when I have it try it says it can not locate the info on the pages.
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
cuda
Ok you have no code showing on your home page now. Put that slash back and upload the file. Then let me know so I can check it.
cuda
Sorry for the delay Cuda, the email notification got lost amongst some other mail.
I put the / back in the code.
http://www.buysoul.com
thank you,
betty
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
bettysue
Sorry for the delay Cuda, the email notification got lost amongst some other mail.
I put the / back in the code.
http://www.buysoul.com
thank you,
betty
Looks like you got it Bettysue, as far as I can see all the code is there that you need to track your site. Enjoy the stat's they can be very helpful!
cuda
-
Re: Simple Google Analytics - Support
Thank you Cuda and Dr. Byte for the help and advise!!
betty
-
Re: Simple Google Analytics - Support
i just installed it, it works great!
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
cuda
Hey nellie I am back to help....
ok first things first view the source of your home page:
Thanks Cuda, been away for a few days. I have removed the hard coded script in the footer, it now looks right when you view the source. Iwill have to contact Paygate re the dummy creditcard No, I dont have it off hand.
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
Nellie
Thanks Cuda, been away for a few days. I have removed the hard coded script in the footer, it now looks right when you view the source. Iwill have to contact Paygate re the dummy creditcard No, I dont have it off hand.
sounds good nellie just pm me the code so it is not out for everyone to see here on the forums.
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
Nellie
Thanks Cuda, been away for a few days. I have removed the hard coded script in the footer, it now looks right when you view the source. Iwill have to contact Paygate re the dummy creditcard No, I dont have it off hand.
Ok I got to the checkout success page using the HSBC payment method, the cc number you gave just always kicked me back to your payment page after I entered it. At the bottom of your checkout success page your code is only the standard tracking code:
Code:
<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "UA-xxxxxx-x";
urchinTracker();
</script>
Also on this page you do not have properly formated html because you do not have any </html> or </body> clossing tags. But that is besides the point...
It appears your your_template/google_analytics/google_analytics.php is not functioning properly. What you should see on your checkout_success page is something like this:
Code:
<script src="https://ssl.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "UA-XXXXXX-1";
urchinTracker();
</script><form style="display:none;" name="utmform">
<textarea id="utmtrans">UTM:T|6||62.78|0.00|35.28|TEST|Louisiana|United States UTM:I|6|1191|product name|2.00|1</textarea>
</form>
Notice the hidden form with the transaction data. Try to upload the your_template/google_analytics/google_analytics.php file again. Also make sure you removed the hard coded google code and only have this at the bottom of your template just before the </body> tag:
PHP Code:
<?php
if (file_exists($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php'))
{
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
}
?>
Then do a test transaction and view your source to see if you get the hidden transaction form....report back
-
Re: Simple Google Analytics - Support
Cuda, don't know if I got an old set of files, but my your_template/google_analytics/google_analytics.php does not have a closing body tag. These are the last few lines of code:
Code:
//echo transaction data
echo '<form style="display:none;" name="utmform">
<textarea id="utmtrans">'
. addslashes($transaction) . ' '
. addslashes(trim($items))
. '</textarea>
</form>';
}
?>
Is this a problem?
-
Re: Simple Google Analytics - Support
Uploaded a new copy of your_template/google_analytics/google_analytics.php, but still not getting the hidden form.
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
Nellie
Cuda, don't know if I got an old set of files, but my your_template/google_analytics/google_analytics.php does not have a closing body tag. These are the last few lines of code:
Code:
//echo transaction data
echo '<form style="display:none;" name="utmform">
<textarea id="utmtrans">'
. addslashes($transaction) . ' '
. addslashes(trim($items))
. '</textarea>
</form>';
}
?>
Is this a problem?
Nellie there should be no closing tag in any of this modules files that should be in your main site template. Make sure the code at the bottom of your templates/[your_template]/common/tpl_main_page.php just before the body tag is:
PHP Code:
<?php
if (file_exists($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php'))
{
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
}
?>
Is it there?
-
Re: Simple Google Analytics - Support
This is what I have at the end of templates/[your_template]/common/tpl_main_page.php :
Code:
<td align="center" colspan="3"><div class="banners"><?php echo zen_display_banner('static', $banner); ?></div> </td>
</tr>
<?php
}
}
?>
</table>
<?php require(DIR_WS_MODULES . 'footer.php'); ?>
<?php
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
?>
</body>
-
Re: Simple Google Analytics - Support
why all the drama? i just pasted the google code into the footer and it works fine for me. am i missing something?
-
Re: Simple Google Analytics - Support
It just started working> Erased post
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
Rhitty
why all the drama? i just pasted the google code into the footer and it works fine for me. am i missing something?
You are missing transaction data...How much people spend on what products from which source....this information can be very helpful this mod allows you to track your transactions.
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
Nellie
This is what I have at the end of templates/[your_template]/common/tpl_main_page.php :
Code:
<td align="center" colspan="3"><div class="banners"><?php echo zen_display_banner('static', $banner); ?></div> </td>
</tr>
<?php
}
}
?>
</table>
<?php require(DIR_WS_MODULES . 'footer.php'); ?>
<?php
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
?>
</body>
What version of Zen are you using Nellie?
-
Re: Simple Google Analytics - Support
Ok, I thought this mod was working just fine (thanks!), but I just discovered an error message showing up on my checkout success page:
Code:
1054 Unknown column 'GOOGLE_ANALYTICS_TARGET_city' in 'field list'
in:
[select orders_id, GOOGLE_ANALYTICS_TARGET_city as city, GOOGLE_ANALYTICS_TARGET_state as state, GOOGLE_ANALYTICS_TARGET_country as country from orders where customers_id = 35 order by date_purchased desc limit 1]
Any suggestions on this? I haven't seen the error on any other page yet. I've double-checked my tpl_main_page.php, and the code is correct. Thanks for any help!
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
peggyc
Hmm, I'm using JRox too -- I wonder if there's some incompatibilty there causing this Analytics problem?
Has anyone determined if JROX works with analytics?
Because I like analytics and I don't want anymore huge headaches:yuck:
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
buzzville
Ok, I thought this mod was working just fine (thanks!), but I just discovered an error message showing up on my checkout success page:
Code:
1054 Unknown column 'GOOGLE_ANALYTICS_TARGET_city' in 'field list'
in:
[select orders_id, GOOGLE_ANALYTICS_TARGET_city as city, GOOGLE_ANALYTICS_TARGET_state as state, GOOGLE_ANALYTICS_TARGET_country as country from orders where customers_id = 35 order by date_purchased desc limit 1]
Any suggestions on this? I haven't seen the error on any other page yet. I've double-checked my tpl_main_page.php, and the code is correct. Thanks for any help!
The GOOGLE_ANALYTICS_TARGET is set in the admin->Google Analytics Config. Do you have a setting there in your admin?
You would only see this error on the checkout_success page as it is only called when an order is completed.
-
Re: Simple Google Analytics - Support
my zen-cart version is 1.3.6
after i install Simple Google Analytics, the google analytics home page show error:
Tracking not yet added to your website: www.enjoyhobbies.net
my webiste is http://www.enjoyhobbies.net
Please help me to resolve the issue.
Thanks.
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
samhuang
my zen-cart version is 1.3.6
after i install Simple Google Analytics, the google analytics home page show error:
Tracking not yet added to your website:
www.enjoyhobbies.net
my webiste is
http://www.enjoyhobbies.net
Please help me to resolve the issue.
Thanks.
You have not entered your correct account number in the admin your current setting is 'enjoyhobbies' see the code below which is at the bottom of your source:
Code:
<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "enjoyhobbies";
urchinTracker();
</script>
account numbers take the form of: UA-XXXXXX-X you can find the account number when you log into your google analytics account and click edit then verify account. hope that helps
-
Re: Simple Google Analytics - Support
Cuda:
I have been working to get your script working perfectly. All was going great. And I see my google account number at the bottom of the source code. And analytics is showing visits to the "cart" directory.
But when I place an item in my cart, and move thru main_page=shopping_cart, click "go to check out" where I arrive at main_page=login, then I get an "errors on page" at the bottom of the browser. I assume this is a javasript error, but I am not sure. It is a yellow triangle with an exclamation point.
One interesting note:
I was trying to find the problem, so I deleted the <?php
require($template->get_template_dir('.php',DIR_WS_TEMPLATE, $current_page_base,'google_analytics') . '/google_analytics.php');
?> at the bottom of tpl_main_page, verified on the server source code that it was gone, but I still saw the error. I am quite certain there were not any errors before installing the analytics script, because I was keeping a close eye on that. Do you know why this would be? I have since put the code back into tpl_main_page. Perhaps this is not related to the script. But it seems like it is. Sorry for the long email.
Any advice?
I would greatly appreciate it.:smile:
-
Re: Simple Google Analytics - Support
Never mind for now, I think it might have something to do with the way I customized the customer login fileds.
-
Re: Simple Google Analytics - Support
Actually, it looks like I might have a conflict coming from payment.php in the classes directory. Should this javascript be renamed?
I would like to open this question up to the community.
Thank you in advance.
-
Re: Simple Google Analytics - Support
I've just installed this mod (in the past I used Andrew includes version, but it sometimes don't tracked the orders), but this mod don't track the orders I made for testing...
I hope this mod track next orders!
Visits are tracked!
-
Re: Simple Google Analytics - Support
My cart is up and running again. Google Analytics are installed and tracking. It turns out the google code was only coincidental to my problem.
Zen-cart is cool.:smile:
-
Re: Simple Google Analytics - Support
I confirm: Google don't track the transaction for me www.100asa.it ! :-(
Why this?
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
100asa
I confirm: Google don't track the transaction for me
www.100asa.it ! :-(
Why this?
Not sure why you are not tracking transactions I tried to create an account for your shop and I did but it would not let me ship to that location so I could not go through the checkout process. The process was also not secured by an SSL cert which is never a good idea. :shocking:
But if you PM me a good login with an address I can use to go through the checkout process I will take a look and give you my two cents....
-
Re: Simple Google Analytics - Support
OK, now you can complete your test order with your account (modified by me), so you can ceck what's the problem! Thank you for your time!
you can contact me by Skype: centoasa
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
100asa
OK, now you can complete your test order with your account (modified by me), so you can ceck what's the problem! Thank you for your time!
you can contact me by Skype: centoasa
All the code that is needed when I checkout with payment method by check (or whatever I choose, only a one language american here) was there.
So I am not sure what you are missing here. Did you allow at least 3-24 hours pass before you checked in google analyitcs for the tracking info. Google Analytics does not report in real time so this lag maybe your problem. What version of zen cart are you running? What payment methods where the previous orders using you where trying to track?
-
Re: Simple Google Analytics - Support
It's strange! I'm waiting past 48hours, but transsaction still not tracked...
I'm waiting Analytics track your order... I hope!
-
Re: Simple Google Analytics - Support
At this time analytics don't have track your order, Cuda!
:-(
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
100asa
At this time analytics don't have track your order, Cuda!
:-(
Not sure why you are not tracking....check your analytics account number and then see this page
http://www.google.com/support/analyt...g&topic=&type=
and make sure the formating of the hidden form is correct. I was going to check again but looks like you deleted my test account allready. Good luck let us know if you find the problem.
-
Re: Simple Google Analytics - Support
I must be having a really bad day...
the readme says:
admin->configuration->google analytics configuration
My problem is the download doesn't come with any ADMIN files. Is it just me ?
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
virtualahmad
I must be having a really bad day...
the readme says:
admin->configuration->google analytics configuration
My problem is the download doesn't come with any ADMIN files. Is it just me ?
Did you get it to work? There are no admin files needed just the sql patch. Let me know if you need helpf...
-
Re: Simple Google Analytics - Support
i did.... the problem was a lack of coffee i think... it was there all along...
-
Re: Simple Google Analytics - Support
Hi,
I am kind of new at this so sorry if this is a dumb question.
When I am uploading the folders on to my site should the google_analytics folder be installed in:
includes/templates/mytemplate/ ?
or
includes/templates/mytemplates/jscript ?
Do I dump the folder in there or just move the contents of the folder into it. For example should it read:
includes/templates/mytemplates/jscript/google_analytics/
or
includes/templates/mytemplates/jscript/google_analytics.php
I was also wondering if thier is an install for the yahoo site tracker jscript?
Thanks
Hector
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
radiof
Hi,
I am kind of new at this so sorry if this is a dumb question.
When I am uploading the folders on to my site should the google_analytics folder be installed in:
includes/templates/mytemplate/ ?
or
includes/templates/mytemplates/jscript ?
Do I dump the folder in there or just move the contents of the folder into it. For example should it read:
includes/templates/mytemplates/jscript/google_analytics/
or
includes/templates/mytemplates/jscript/google_analytics.php
I was also wondering if thier is an install for the yahoo site tracker jscript?
Thanks
Hector
When uploading mod files the stucture should be the same as they are in the downloaded file (unless noted otherwise in the readme) this goes for all mods.
So for this mod your path to the google_analytics folder should be:
includes\templates\your_template\google_analytics
There is no jscript folder so nothing to upload there, are you sure you are on the right thread? There is another google analytics mod it is here:
http://www.zen-cart.com/forum/showthread.php?t=43907
there is no yahoo site tracker provided with this mod.....google analytics will track plenty of info and you probably will have no need for the yahoo site tracker....if you are running yahoo ads (or any ads, campaigns for that matter) you can track them by tagging your link urls with google analytics variables see here for an explanation:
http://www.epikone.com/blog/2006/11/...-link-tagging/
let me know if you need anything else
-
Re: Simple Google Analytics - Support
I installed Simple Google Analytics yesterday and I keep checking Google Analytics but I am still getting this message:
-------------------
Tracking Status Information
Profile Name: www.horse-logos.com
Website URL: www.horse-logos.com
Tracking Not Installed (Last checked: 2007-04-06 1:08 PM PST.)
The Google Analytics tracking code has not been detected on your website's home page. For Analytics to function, you or your web administrator must add the code to each page of your website.
-------------------
This code is on the bottom of my cart pages...
<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "UA-1623104";
urchinTracker();
</script></body></html>
So what did I do wrong or do I just have to wait on Google for longer?
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
jonisolis
I installed Simple Google Analytics yesterday and I keep checking Google Analytics but I am still getting this message:
-------------------
Tracking Status Information
Profile Name:
www.horse-logos.com
Website URL:
www.horse-logos.com
Tracking Not Installed (Last checked: 2007-04-06 1:08 PM PST.)
The Google Analytics tracking code has not been detected on your website's home page. For Analytics to function, you or your web administrator must add the code to each page of your website.
-------------------
This code is on the bottom of my cart pages...
<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "UA-1623104";
urchinTracker();
</script></body></html>
So what did I do wrong or do I just have to wait on Google for longer?
Easy fix for you :clap: .... all you need is your site number (not really sure what it is called to tell you the truth) which is usually just -1 but check your account number in g analytics. So in the admin you need to enter "UA-1623104-1" or if you are tracking more then one site whatever site number this site is...let me know if you need anything else and that I am making sense
-
Re: Simple Google Analytics - Support
I just installed this and it appears to be working, now I am trying to set up a goal. For the "Goal URL" what should I put? I just did a test order and the thank you page url was:
https://www.domain.com/index.php?main_page=checkout_success&zenid=387aa9ebf4f1967f3c7beb63c2d21ade
so do I put:
https://www.domain.com/index.php?main_page=checkout_success
will the zenid at the end cause a problem?
-
Re: Simple Google Analytics - Support
Hi all,
I'm keen to add Google Analytics support to my 1.3.7 cart but am a little confused here..
There seem to be two major threads on the subject. This one I'm posting in refers to The Simple Google Analytics mod that is in the official downloads section. The other thread is not clear at all, but I understand it's a different mod.
Is that the case.. and which one is the one to use?
Also.. I've downloaded the one off the site here and it says it's for 1.3.6 Does it work on 1.3.7? I've searched the forum for that, but no luck.
And finally, if I install it.. just how risky is this mod regarding future cart upgrades? I'm trying not to install anything that is going to make things difficult down the line.
Thanks for any advice on this,
Rob
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
xemiterx
You do not want your zenid in the url....for goal tracking the checkout_success page is the final goal and you can add all the steps up to that point....just do a test order and everytime you go to the next step enter the url in one of the goal steps...not to hard to do
cuda
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
robax
Hi all,
I'm keen to add Google Analytics support to my 1.3.7 cart but am a little confused here..
There seem to be two major threads on the subject. This one I'm posting in refers to The Simple Google Analytics mod that is in the official downloads section. The other thread is not clear at all, but I understand it's a different mod.
Is that the case.. and which one is the one to use?
Also.. I've downloaded the one off the site here and it says it's for 1.3.6 Does it work on 1.3.7? I've searched the forum for that, but no luck.
And finally, if I install it.. just how risky is this mod regarding future cart upgrades? I'm trying not to install anything that is going to make things difficult down the line.
Thanks for any advice on this,
Rob
This should work fine with 1.3.7 and should be easy to upgrade to new releases. There is another mod similar to this one available I just found people were having some dificulties with it and I made this one simple....at least I tried to. Let me know if I can help
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
cuda
This should work fine with 1.3.7 and should be easy to upgrade to new releases. There is another mod similar to this one available I just found people were having some dificulties with it and I made this one simple....at least I tried to. Let me know if I can help
Great stuff, thanks for the update Cuda. I'll go and try it out :smile:
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
cuda
I made this one simple....
Wow! You made? Really? Ok, I remove this another mod.
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
a_berezin
Wow! You made? Really? Ok, I remove this another mod.
a_berezin let me clarify I reworked your original mod so a lot of the code is yours....I did not mean to offend if I have I appoligize :hug: You do great work...keep it up!!! I was just explaining what this mod was it is a variation of yours....the beauty of open source!
-
Re: Simple Google Analytics - Support
Yes Andrew, I also understood that exactly as Cuda has stated.
The word 'made' in English doesn't have to mean 'created'. It just means he 'changed' or 'altered' it to be simpler.
Thanks both of you.
-
Re: Simple Google Analytics - Support
This "Simple Google Analytics":
- does not support multi-currency operations;
- has problems with some payment systems.
P.S. I don't need any answer or comments.
-
Re: Simple Google Analytics - Support
I posted this over on the Google Analytics Integration thread from a_berezin and just wanted everyone to see it....
a_berezin and all others I apologize for any confusion or strife I have caused anyone....Below is my post that has caused this issue made in the thread for the fork of his mod Google Analytics Integration which I named Simple Google Analytics
Quote:
This should work fine with 1.3.7 and should be easy to upgrade to new releases. There is another mod similar to this one available I just found people were having some difficulties with it and I made this one simple....at least I tried to. Let me know if I can help
found here: http://www.zen-cart.com/forum/showth...=53701&page=10
a_berezin is the original coder of this mod no doubt and all of his work on zen cart is outstanding and I myself use many of his mods. I would also like to urge a_berezin to not drop his support for this mod...This is the spirit of opensource everyone can have a shot at doing it there way some may like a_berezin's way and others my modded way. It all started out the same much like linux or zen cart for that matter. Zen Cart itself forked from osCommerce and now is much different but some of the code from osCommerce remains. This is a community here at zen cart and the heart of any opensource community is those who are willing to contribute....I saw an opportunity so I contributed this is what keeps opensource alive, I think most will agree with me....
so I really want to say I am sorry for the slight slip in words to a_berezin and urge him to not throw in the towel and keep that fire burning...
Sincerly
Cuda
-
Re: Simple Google Analytics - Support
Newb question:
What's the difference between using this download or just posting Google's tracking code directly to the "templates/custom/common/tpl_main_page.php"?
-
Re: Simple Google Analytics - Support
Quote:
Originally Posted by
onelove5683
Newb question:
What's the difference between using this download or just posting Google's tracking code directly to the "templates/custom/common/tpl_main_page.php"?
you can track transactions too...what you sold and when