trying to get google analytics working

This commit is contained in:
maxwell 2010-06-29 13:58:36 -07:00
parent 60336bd520
commit 6532962c1c
2 changed files with 12 additions and 12 deletions

View file

@ -9,10 +9,20 @@
= stylesheet_link_tag "blueprint/screen", :media => 'screen'
= stylesheet_link_tag "application"
/= javascript_include_tag"http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"
= javascript_include_tag 'jquery142', 'rails', 'view', 'google'
= javascript_include_tag 'jquery142', 'rails', 'view'
= javascript_include_tag 'tiny_mce/tiny_mce.js'
:javascript
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-17207587-1']);
_gaq.push(['_setDomainName', '#{root_url}']);
_gaq.push(['_trackPageview']);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();
- unless request.user_agent.include? "Safari" ||"Chrome"
= javascript_include_tag 'FABridge', 'swfobject', 'web_socket'
:javascript

View file

@ -1,10 +0,0 @@
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-17207587-1']);
_gaq.push(['_setDomainName', '.joindiaspora.com']);
_gaq.push(['_trackPageview']);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();