User Tools

Site Tools


tutorials:using_javascript_in_smarty_templates:start

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
tutorials:using_javascript_in_smarty_templates:start [2011/11/28 21:08]
matt
tutorials:using_javascript_in_smarty_templates:start [2014/09/25 16:55] (current)
Line 7: Line 7:
 There are a couple of ways around this. You can either replace all of the left-curly-braces in your Javascript with the {ldelim} tag, or you can simply wrap the entire javascript code in **{literal}{/literal}** SMARTY tags. There are a couple of ways around this. You can either replace all of the left-curly-braces in your Javascript with the {ldelim} tag, or you can simply wrap the entire javascript code in **{literal}{/literal}** SMARTY tags.
  
-<tip c n>**Google Analytics Tip:**  If you are trying to use Google Analytics:  Edit the **foot.tpl** template file in the admin panel under **Design > Manager**.  Click on the **<..> Source Code Editor** tab.  Right before the end **</body>** tag, copy/paste in the Google Analytics code as provided by Google Analytics.  Right before it, add **{literal}**, and right after the code you pasted in, add **{/literal}**.  See below for examples of what it might look like when you are done.</tip>+<tip c n>**Google Analytics Tip:**  If you are trying to use Google Analytics:  Edit the **footer.tpl** template file in the admin panel under **Design > Manager**.  Click on the **<..> Source Code Editor** tab.  Right before the end **</body>** tag, copy/paste in the Google Analytics code as provided by Google Analytics.  Right before it, add **{literal}**, and right after the code you pasted in, add **{/literal}**.  See below for examples of what it might look like when you are done.</tip>
  
 We'll show the oft-offending piece of Google Analytics code here, by way of example. Google generally supplies the code like this: We'll show the oft-offending piece of Google Analytics code here, by way of example. Google generally supplies the code like this:
tutorials/using_javascript_in_smarty_templates/start.1322514493.txt.gz · Last modified: 2014/09/25 16:55 (external edit)