Products » Support Forums 

Support Forums

HomeHomeDotNetNuke Modu...DotNetNuke Modu...Google Analytic...Google Analytic...Tracking Registered UsersTracking Registered Users
Previous
 
Next
New Post
1/7/2010 11:02 PM
 

Can you please explain more on how to track registered users?

You have the following option:

Track registered users as separate Analytics segment?  By checking this, you can filter your Google Analytics by a 'Regsitered User' segment. Use a filter pattern of 'Users'. This will track any registered user of the system.

Is this supposed to emit a setVar variable so that GA can use segments?  I am not seeing a setVar emitted when this is checked.

Thanks,

Rich

 

 
New Post
1/8/2010 2:41 AM
 

Hi Rich

Yes, this will emit a 'setVar' of 'User' in your ga.js code.  In order to see it, you'll need to be logged on as a registered user - also make sure you're not logged on as an administrator if you've excluded administration traffic.

In my test site, here's the output from the module:

script type='text/javascript' src='http://www.google-analytics.com/ga.js'></script>
<script type='text/javascript'>
var pageTracker = _gat._getTracker("UA-1235465-5");
pageTracker._setSessionTimeout('1800');
pageTracker._initData();
/*pageTracker._trackVisit(); commented out due to match on TESTMACHINE */
pageTracker._setVar('User');
</script>

Note the actual call to _trackVisit() is commented out automatically because I have the "Do not generate tracking script for calls to this host " setting set to 'TESTMACHINE' on my test server, so that I'm not actually calling analytics.  However, the code is exactly the same in every other respect to a live site.

 
New Post
1/8/2010 3:16 AM
 

Thanks Mate! But still getting no setVar. Is this iFinity script or maybe default DNN Google Analytics module script?

                <script type="text/javascript">
                var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
                document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
                script>

                <script type="text/javascript">
                var pageTracker = _gat._getTracker("UA-12260630-1");
                pageTracker._trackPageview();
                script>

My Settings are thus:
View Module Edit Module
Administrators Permission Granted Permission Granted
All Users Not Specified Not Specified
NE Beta Users Not Specified Not Specified
NW Beta Users Not Specified Not Specified
Registered Users Not Specified Not Specified
Subscribers Not Specified Not Specified
Unauthenticated Users Not Specified Not Specified






 
New Post
1/8/2010 3:29 AM
 

That;'s not the ifinity script.  It uses server side logic to determine http/https, and it also inserts the ga.js reference at the server side.  I'm not sure if is the standard DNN ga script, I haven't really looked at the default install.

I'd say the problem with your install is that you don't have 'all users' ticked in you module permissions.  Without this ticked, the module is not going to output the script for regular users - only for administrators.  And if you have the 'do not generate script for memebers of this group' then you won't see it at all.

 
New Post
1/8/2010 7:39 AM
 

Thanks Bruce,

Now that I look around the source code more, I do see your script is there complete with the setVar().  The problem is, so is the DNN script.  The DNN script is after your script so maybe it is taking precedence?  Anyway, I thought your module would replace the default DNN script.

I am usig DNN Community 5.1 which has a basic GA script as a default (shown above).  The Professional version of  DNN 5.1 has a GA with setVar() options like yours.  Have you tested yours with version 5.1?  Will yours replace the default DNN GA script?

My page code ends with the following:

<script type="text/javascript" src="/DNN3/Resources/Shared/scripts/initWidgets.js" ></script><script type='text/javascript' src='/DNN3/DesktopModules/iFinity.GoogleAnalytics/js/taglinks.js'></script>
<script type='text/javascript' src='http://www.google-analytics.com/ga.js'></script>
<script type='text/javascript'>
var pageTracker = _gat._getTracker("UA-12260630-1");
pageTracker._setSessionTimeout('1800');
pageTracker._initData();
pageTracker._trackPageview();
pageTracker._setVar('User');
</script>
<script type="text/javascript">
//<![CDATA[
Sys.Application.initialize();
//]]>
</script>
                <script type="text/javascript">
                var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
                document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
                </script>

                <script type="text/javascript">
                var pageTracker = _gat._getTracker("UA-12260630-1");
                pageTracker._trackPageview();
                </script>           
            </body>
</html>

Rich

 

 
Previous
 
Next
HomeHomeDotNetNuke Modu...DotNetNuke Modu...Google Analytic...Google Analytic...Tracking Registered UsersTracking Registered Users


Support Guidelines.. Please read before posting

To get support on iFinity products and services, please search the forums for the the answer to the problem you are seeking. If you cannot find a solution, post a question in the relevant forum.   Ensure that you specify the relevant versions of the problem, and the actual error message or a detailed description of the problem.    You will need to register with this site to post on the forum.  If you have a Microsoft Live (Hotmail/Passport) account you can use that.  If you have a Open Id account you can use that.  If you neither of these, you will need to register a user Id and password.