<?xml version="1.0" encoding="UTF-8"?><!-- generator="bbPress" -->

<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
>

<channel>
<title>ThemeShaper Forums Topic: Adding Google Analytics code in footer</title>
<link>http://themeshaper.com/forums/</link>
<description>Help In Shaping WordPress Themes</description>
<language>en</language>
<pubDate>Thu, 09 Feb 2012 00:05:29 +0000</pubDate>

<item>
<title>dandam on "Adding Google Analytics code in footer"</title>
<link>http://themeshaper.com/forums/topic/adding-google-analytics-code-in-footer#post-10647</link>
<pubDate>Wed, 10 Mar 2010 20:48:19 +0000</pubDate>
<dc:creator>dandam</dc:creator>
<guid isPermaLink="false">10647@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;Thanks for the escape tip/reminder. &#60;/p&#62;
&#60;p&#62;Using Thematic 0.9.5.1 I was able to use the thematic_after action to add GA script to the footer no problem.
&#60;/p&#62;</description>
</item>
<item>
<title>zanguanga on "Adding Google Analytics code in footer"</title>
<link>http://themeshaper.com/forums/topic/adding-google-analytics-code-in-footer#post-4889</link>
<pubDate>Thu, 02 Jul 2009 22:39:58 +0000</pubDate>
<dc:creator>zanguanga</dc:creator>
<guid isPermaLink="false">4889@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;@cotinus&#60;br /&#62;
I have copied the file footer.php into the folder of childtheme, and have written tehe Google Analytics code right before the label &#60;code&#62;&#38;lt;/body&#38;gt;&#60;/code&#62;&#60;/p&#62;
&#60;p&#62;@Chris&#60;br /&#62;
Vielen Dank! your code works perfectly :-)
&#60;/p&#62;</description>
</item>
<item>
<title>Chris on "Adding Google Analytics code in footer"</title>
<link>http://themeshaper.com/forums/topic/adding-google-analytics-code-in-footer#post-4866</link>
<pubDate>Thu, 02 Jul 2009 11:10:32 +0000</pubDate>
<dc:creator>Chris</dc:creator>
<guid isPermaLink="false">4866@http://themeshaper.com/forums/</guid>
<description>&#60;pre&#62;&#60;code&#62;function childtheme_after() {
echo &#38;#39;&#38;lt;script type=&#38;quot;text/javascript&#38;quot;&#38;gt;&#38;#39;;
echo &#38;#39;var gaJsHost = ((&#38;quot;https:&#38;quot; == document.location.protocol) ? &#38;quot;https://ssl.&#38;quot; : &#38;quot;http://www.&#38;quot;);&#38;#39;;
echo &#38;#39;document.write(unescape(&#38;quot;%3Cscript src=\&#38;#39;&#38;quot; + gaJsHost + &#38;quot;google-analytics.com/ga.js\&#38;#39; type=\&#38;#39;text/javascript\&#38;#39;%3E%3C/script%3E&#38;quot;));&#38;#39;;
echo &#38;#39;&#38;lt;/script&#38;gt;&#38;#39;;
echo &#38;#39;&#38;lt;script type=&#38;quot;text/javascript&#38;quot;&#38;gt;&#38;#39;;
echo &#38;#39;try {&#38;#39;;
echo &#38;#39;var pageTracker = _gat._getTracker(&#38;quot;UA-0000000-0&#38;quot;);&#38;#39;;
echo &#38;#39;pageTracker._trackPageview();&#38;#39;;
echo &#38;#39;} catch(err) {}&#38;lt;/script&#38;gt;&#38;#39;;
}
add_action(&#38;#39;thematic_after&#38;#39;, &#38;#39;childtheme_after&#38;#39;);&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;You need to escape the '&#60;/p&#62;
&#60;p&#62;Chris
&#60;/p&#62;</description>
</item>
<item>
<title>cotinus on "Adding Google Analytics code in footer"</title>
<link>http://themeshaper.com/forums/topic/adding-google-analytics-code-in-footer#post-4864</link>
<pubDate>Thu, 02 Jul 2009 10:50:23 +0000</pubDate>
<dc:creator>cotinus</dc:creator>
<guid isPermaLink="false">4864@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;@zanguanga&#60;/p&#62;
&#60;p&#62;Glad it's working!&#60;/p&#62;
&#60;p&#62;Can you share what you changed in the code?
&#60;/p&#62;</description>
</item>
<item>
<title>zanguanga on "Adding Google Analytics code in footer"</title>
<link>http://themeshaper.com/forums/topic/adding-google-analytics-code-in-footer#post-4859</link>
<pubDate>Wed, 01 Jul 2009 21:13:50 +0000</pubDate>
<dc:creator>zanguanga</dc:creator>
<guid isPermaLink="false">4859@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;Finally I have put the code in footer.php :/
&#60;/p&#62;</description>
</item>
<item>
<title>Chris on "Adding Google Analytics code in footer"</title>
<link>http://themeshaper.com/forums/topic/adding-google-analytics-code-in-footer#post-4849</link>
<pubDate>Wed, 01 Jul 2009 09:48:07 +0000</pubDate>
<dc:creator>Chris</dc:creator>
<guid isPermaLink="false">4849@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;Sorry .. checked only the method not the code.&#60;/p&#62;
&#60;p&#62;Chris
&#60;/p&#62;</description>
</item>
<item>
<title>zanguanga on "Adding Google Analytics code in footer"</title>
<link>http://themeshaper.com/forums/topic/adding-google-analytics-code-in-footer#post-4839</link>
<pubDate>Tue, 30 Jun 2009 17:09:29 +0000</pubDate>
<dc:creator>zanguanga</dc:creator>
<guid isPermaLink="false">4839@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;Hi,&#60;br /&#62;
you have already verified that I am not programmer :/&#60;/p&#62;
&#60;p&#62;This gives back an error to me in line 42&#60;br /&#62;
Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ',' or ';'&#60;/p&#62;
&#60;p&#62;Line 42:&#60;/p&#62;
&#60;p&#62;&#60;code&#62;document.write(unescape(&#34;%3Cscript src='&#34; + gaJsHost + &#34;google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E&#34;));&#60;/code&#62;
&#60;/p&#62;</description>
</item>
<item>
<title>Chris on "Adding Google Analytics code in footer"</title>
<link>http://themeshaper.com/forums/topic/adding-google-analytics-code-in-footer#post-4835</link>
<pubDate>Tue, 30 Jun 2009 14:53:33 +0000</pubDate>
<dc:creator>Chris</dc:creator>
<guid isPermaLink="false">4835@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;Hi,&#60;/p&#62;
&#60;p&#62;this can't work .. you're trying to filter an action hook :-)&#60;/p&#62;
&#60;p&#62;Ok .. it's:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;function childtheme_after() {
echo &#38;#39;
&#38;lt;script type=&#38;quot;text/javascript&#38;quot;&#38;gt;
var gaJsHost = ((&#38;quot;https:&#38;quot; == document.location.protocol) ? &#38;quot;https://ssl.&#38;quot; : &#38;quot;http://www.&#38;quot;);
document.write(unescape(&#38;quot;%3Cscript src=&#38;#39;&#38;quot; + gaJsHost + &#38;quot;google-analytics.com/ga.js&#38;#39; type=&#38;#39;text/javascript&#38;#39;%3E%3C/script%3E&#38;quot;));
&#38;lt;/script&#38;gt;
&#38;lt;script type=&#38;quot;text/javascript&#38;quot;&#38;gt;
try {
var pageTracker = _gat._getTracker(&#38;quot;UA-0000000-0&#38;quot;);
pageTracker._trackPageview();
} catch(err) {}&#38;lt;/script&#38;gt;
&#38;#39;;
}
add_action(&#38;#39;thematic_after&#38;#39;, &#38;#39;childtheme_after&#38;#39;);&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;Chris
&#60;/p&#62;</description>
</item>
<item>
<title>zanguanga on "Adding Google Analytics code in footer"</title>
<link>http://themeshaper.com/forums/topic/adding-google-analytics-code-in-footer#post-4833</link>
<pubDate>Tue, 30 Jun 2009 14:40:30 +0000</pubDate>
<dc:creator>zanguanga</dc:creator>
<guid isPermaLink="false">4833@http://themeshaper.com/forums/</guid>
<description>&#60;p&#62;Hello&#60;br /&#62;
I do not know what I do bad in childtheme, but does not work&#60;/p&#62;
&#60;p&#62;&#60;code&#62;function childtheme_after() {&#60;br /&#62;
    return '&#60;br /&#62;
&#38;lt;script type=&#34;text/javascript&#34;&#38;gt;&#60;br /&#62;
var gaJsHost = ((&#34;https:&#34; == document.location.protocol) ? &#34;https://ssl.&#34; : &#34;http://www.&#34;);&#60;br /&#62;
document.write(unescape(&#34;%3Cscript src='&#34; + gaJsHost + &#34;google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E&#34;));&#60;br /&#62;
&#38;lt;/script&#38;gt;&#60;br /&#62;
&#38;lt;script type=&#34;text/javascript&#34;&#38;gt;&#60;br /&#62;
try {&#60;br /&#62;
var pageTracker = _gat._getTracker(&#34;UA-0000000-0&#34;);&#60;br /&#62;
pageTracker._trackPageview();&#60;br /&#62;
} catch(err) {}&#38;lt;/script&#38;gt;&#60;br /&#62;
';&#60;br /&#62;
}&#60;br /&#62;
add_filter('thematic_after', 'childtheme_after');&#60;/code&#62;
&#60;/p&#62;</description>
</item>

</channel>
</rss>

