Changes between Version 1 and Version 2 of GoogleTranslateTimelineScript


Ignore:
Timestamp:
Dec 9, 2008 6:43:19 PM (5 years ago)
Author:
techtonik
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • GoogleTranslateTimelineScript

    v1 v2  
    2323== Example == 
    2424 
    25 Place '''timeline.translate.js''' into your project ''htdocs/'' directory. Merge the following snippet into environment's ''templates/site.html'' head section: 
     25Place '''timeline.translate.js''' into your project ''htdocs/'' directory. Merge the following '''site.html''' example with your environment's ''templates/site.html'' head section: 
    2626 
    2727{{{ 
    28   <head py:match="head" py:attrs="select('@*')"> 
     28#!xml 
     29<html xmlns="http://www.w3.org/1999/xhtml" 
     30      xmlns:py="http://genshi.edgewall.org/" py:strip=""> 
     31  <!-- Custom match templates go here --> 
     32 
     33  <head py:match="head" py:attrs="select('@*')"> 
    2934    ${select('*|comment|text()')} 
    3035 
    31     &lt;py:if test=&#34;req.environ['PATH_INFO'] == '/timeline'&#34;&gt; 
    32       &lt;!-- Timeline specific - changeset comments translation using Google API --&gt; 
    33       &lt;script type=&#34;text/javascript&#34; src=&#34;http://www.google.com/jsapi&#34;&gt;&lt;/script&gt; 
    34       &lt;script type=&#34;text/javascript&#34; src=&#34;${href.chrome('site/timeline.translate.js')}&#34;&gt;&lt;/script&gt; 
    35     &lt;/py:if&gt; 
     36    <py:if test="req.environ['PATH_INFO'] == '/timeline'"> 
     37      <!-- Timeline specific - changeset comment translations using Google API --> 
     38      <script type="text/javascript" src="http://www.google.com/jsapi"></script> 
     39      <script type="text/javascript" src="${href.chrome('site/timeline.translate.js')}"></script> 
     40    </py:if> 
    3641 
    37   &lt;/head&gt; 
     42  </head> 
     43</html> 
    3844}}} 
    3945