Add i18n framework and start tokenizing some strings
Add i18n framework and start tokenizing some strings

--- a/include/controller/ControllerBase.class.php
+++ b/include/controller/ControllerBase.class.php
@@ -241,6 +241,7 @@
 			$this->tpl->assign('search', $this->params['search']);
 		if (isset($this->params['searchtype']))
 			$this->tpl->assign('searchtype', $this->params['searchtype']);
+		$this->tpl->assign('resources', GitPHP_Resource::GetInstance());
 	}
 
 	/**

--- /dev/null
+++ b/include/resource/Resource.class.php
@@ -1,1 +1,79 @@
+<?php
+/**
+ * GitPHP Resource
+ *
+ * Resource factory
+ *
+ * @author Christopher Han <xiphux@gmail.com>
+ * @copyright Copyright (c) 2010 Christopher Han
+ * @package GitPHP
+ * @subpackage Resource
+ */
 
+require_once(GITPHP_RESOURCEDIR . 'ResourceBase.class.php');
+
+/**
+ * Resource
+ *
+ * @package GitPHP
+ * @subpackage Resource
+ */
+class GitPHP_Resource
+{
+	
+	/**
+	 * instance
+	 *
+	 * Stores the singleton instance of the resource provider
+	 *
+	 * @access protected
+	 * @static
+	 */
+	protected static $instance = null;
+
+	/**
+	 * GetInstance
+	 *
+	 * Returns the singleton instance
+	 *
+	 * @access public
+	 * @static
+	 * @return mixed instance of resource class
+	 * @throws Exception if resource provider has not been instantiated yet
+	 */
+	public static function GetInstance()
+	{
+		if (!self::$instance)
+			throw new Exception('Resource provider not instantiated');
+		return self::$instance;
+	}
+
+	/**
+	 * Instantiate
+	 *
+	 * Instantiates the singleton instance
+	 *
+	 * @access public
+	 * @static
+	 * @param string $locale locale to instantiate
+	 * @throws Exception on invalid locale
+	 */
+	public static function Instantiate($locale)
+	{
+		switch ($locale) {
+			case 'en_US':
+				require_once(GITPHP_LOCALEDIR . 'en_US.class.php');
+				self::$instance = new GitPHP_Resource_en_US();
+				break;
+			case 'zz_Debug':
+				require_once(GITPHP_LOCALEDIR . 'zz_Debug.class.php');
+				self::$instance = new GitPHP_Resource_zz_Debug();
+				break;
+			default:
+				throw new Exception('Invalid locale: ' . $locale);
+				break;
+		}
+	}
+
+}
+

--- /dev/null
+++ b/include/resource/ResourceBase.class.php
@@ -1,1 +1,80 @@
+<?php
+/**
+ * GitPHP ResourceBase
+ *
+ * Base class for all resource providers
+ *
+ * @author Christopher Han <xiphux@gmail.com>
+ * @copyright Copyright (c) 2010 Christopher Han
+ * @package GitPHP
+ * @subpackage Resource
+ */
 
+/**
+ * ResourceBase class
+ *
+ * @package GitPHP
+ * @subpackage Resource
+ * @abstract
+ */
+abstract class GitPHP_ResourceBase
+{
+
+	/**
+	 * resources
+	 *
+	 * Array of resources
+	 *
+	 * @access protected
+	 */
+	protected $resources = array();
+
+	/**
+	 * GetResource
+	 *
+	 * Gets a resource
+	 *
+	 * @access public
+	 * @param string $resource resource to fetch
+	 * @param string $domain domain of string (for multiple translations of same string)
+	 * @return string resource
+	 */
+	public function GetResource($resource, $domain = '')
+	{
+		if (!empty($resource)) {
+			
+			$reskey = $resource;
+			if (!empty($domain))
+				$reskey .= '_' . $domain;
+
+			if (isset($this->resources[$reskey])) {
+				return $this->resources[$reskey];
+			}
+
+		}
+
+		/*
+		 * Fallback on English if string hasn't been tokenized
+		 */
+		return $resource;
+	}
+
+	/**
+	 * Format
+	 *
+	 * Looks up an i18n version of a string and formats
+	 * it with the parameters
+	 *
+	 * @access public
+	 * @param string $fmt format string
+	 * @return formatted string resource
+	 */
+	public function Format($fmt)
+	{
+		$args = func_get_args();
+		$x = array_shift($args);
+		return vsprintf($this->GetResource($fmt), $args);
+	}
+
+}
+

--- /dev/null
+++ b/include/resource/locale/en_US.class.php
@@ -1,1 +1,34 @@
+<?php
+/**
+ * GitPHP Resource en_US
+ *
+ * en_US Resource Provider
+ *
+ * @author Christopher Han <xiphux@gmail.com>
+ * @copyright Copyright (c) 2010 Christopher Han
+ * @package GitPHP
+ * @subpackage Resource
+ */
 
+/**
+ * en_US Resource
+ *
+ * @package GitPHP
+ * @subpackage Resource
+ */
+class GitPHP_Resource_en_US extends GitPHP_ResourceBase
+{
+
+	/**
+	 * __construct
+	 *
+	 * Initializes resources
+	 *
+	 * @access public
+	 */
+	public function __construct()
+	{
+	}
+
+}
+

--- /dev/null
+++ b/include/resource/locale/zz_Debug.class.php
@@ -1,1 +1,351 @@
-
+<?php
+/**
+ * GitPHP Resource zz_Debug
+ *
+ * zz_Debug Test Resource Provider
+ *
+ * @author Christopher Han
+ * @copyright Copyright (c) 2010 Christopher Han
+ * @package GitPHP
+ * @subpackage Resource
+ */
+
+/**
+ * zz_Debug Resource
+ *
+ * @package GitPHP
+ * @subpackage Resource
+ */
+class GitPHP_Resource_zz_Debug extends GitPHP_ResourceBase
+{
+	/**
+	 * __construct
+	 *
+	 * Initializes resources
+	 *
+	 * @access public
+	 */
+	public function __construct()
+	{
+		/*
+		 * Link back to the list of projects
+		 * English: projects
+		 */
+		$this->resources['projects'] = '{pŕŏjēĉts•••}';
+		
+		/*
+		 * Used as title for and link to project summary page
+		 * English: summary
+		 */
+		$this->resources['summary'] = '{sȕmmǡry••}';
+		
+		/*
+		 * Used as title for and link to the compact log view
+		 * with one line abbreviated commits
+		 * English: shortlog
+		 */
+		$this->resources['shortlog'] = '{shǫrtlǭg•••}';
+		
+		/*
+		 * Used as title for and link to log view with full
+		 * commit messages
+		 * English: log
+		 */
+		$this->resources['log'] = '{lǿg•}';
+		
+		/*
+		 * Used as title for and link to a list of files
+		 * in a directory, which git calls a 'tree'
+		 * English: tree
+		 */
+		$this->resources['tree'] = '{trëé•}';
+		
+		/*
+		 * Used as link to download a copy of the files
+		 * in a given commit
+		 * English: snapshot
+		 */
+		$this->resources['snapshot'] = '{snápshŏt•••}';
+		
+		/*
+		 * Used as title for search page, and also is the
+		 * label for the search box
+		 * English: search
+		 */
+		$this->resources['search'] = '{sėąrch••}';
+		
+		/*
+		 * Used as link to and title for the full diff of
+		 * all the changes in a commit
+		 * English: commitdiff
+		 */
+		$this->resources['commitdiff'] = '{cŏmmĭtdĩff••••}';
+		
+		/*
+		 * Used as link to and title for a diff of a single file
+		 * English: blobdiff
+		 */
+		$this->resources['blobdiff'] = '{blōbdīff•••}';
+		
+		/*
+		 * Used as link to and title for the file history, which
+		 * displays all commits that have modified a certain file
+		 * English: history
+		 */
+		$this->resources['history'] = '{hįstőry••}';
+		
+		/*
+		 * Used as link to and title for page displaying detailed
+		 * info about a tag
+		 * English: tag
+		 */
+		$this->resources['tag'] = '{tàg•}';
+		
+		/*
+		 * Used as link to and title for page showing all tags
+		 * in a project
+		 * English: tags
+		 */
+		$this->resources['tags'] = '{tãgs•}';
+		
+		/*
+		 * Used as link to and title for page showing all heads
+		 * in a project
+		 * English: heads
+		 */
+		$this->resources['heads'] = '{hêåds•}';
+		
+		/*
+		 * Used as link to and title for page displaying blame info
+		 * (who last touched what line) in a file
+		 * English: blame
+		 */
+		$this->resources['blame'] = '{bläme•}';
+		
+		/*
+		 * Used as link to and title for page displaying a blob,
+		 * which is what git calls a single file
+		 * English: blob
+		 */
+		$this->resources['blob'] = '{blōb•}';
+		
+		/*
+		 * Used as link to and title for page displaying info about
+		 * a single commit in the project
+		 * English: commit
+		 */
+		$this->resources['commit'] = '{cŏmmıt••}';
+		
+		/*
+		 * Used as link to diff this file version with the previous version
+		 * English: diff
+		 */
+		$this->resources['diff'] = '{dĩff•}';
+		
+		/*
+		 * Used as link to diff this file version with the current file
+		 * English: diff to current
+		 */
+		$this->resources['diff to current'] = '{dĭff tō cũrrēnt•••••}';
+		
+		
+		/*
+		 * Used to label the project description
+		 * English: description
+		 */
+		$this->resources['description'] = '{dėscrĩptįon••••}';
+		
+		/*
+		 * Used to label the project owner
+		 * English: owner
+		 */
+		$this->resources['owner'] = '{ōwnęr•}';
+		
+		/*
+		 * Used to label the time the project was last changed
+		 * (the time of the most recent commit)
+		 * English: last change
+		 */
+		$this->resources['last change'] = '{låst chängë••••}';
+		
+		/*
+		 * Used to label the url that users can use to clone the
+		 * project
+		 * English: clone url
+		 */
+		$this->resources['clone url'] = '{clône ũrl•••}';
+		
+		/*
+		 * Used to label the url that users can use to push commits
+		 * to the project
+		 * English: push url
+		 */
+		$this->resources['push url'] = '{půsh ŭrl••}';
+		
+		/*
+		 * Used to label the author of the commit, and as a field to search
+		 * The author is the person who wrote the changes in the commit
+		 * English: author
+		 */
+		$this->resources['author'] = '{åüthōr••}';
+		
+		/*
+		 * Used to label the committer of the commit, and as a field to search
+		 * The committer is the person who put the commit into this project
+		 * English: committer
+		 */
+		$this->resources['committer'] = '{cōmmĭttęr•••}';
+		
+		/*
+		 * Used to label the parent of this commit
+		 * The parent is the commit preceding this one in the project history
+		 * English: parent
+		 */
+		$this->resources['parent'] = '{păręnt••}';
+		
+		/*
+		 * Used as a search type, to search the contents of files in the project
+		 * English: file
+		 */
+		$this->resources['file'] = '{fìlé•}';
+		
+		
+		/*
+		 * Used to indicate the number of files changed in a commit
+		 * Comes before a list of files
+		 * English: %1$d files changed:
+		 * %1$d: the number of files
+		 */
+		$this->resources['%1$d files changed:'] = '{chängëd *%1$d*••••}';
+		
+		/*
+		 * Used to indicate a new object was added with an access mode
+		 * English: new %1$s with mode %2$s
+		 * %1$s: the type of object
+		 * %2$s: the mode
+		 */
+		$this->resources['new %1$s with mode %2$s'] = '{*%2$s* nēw *%1$s*•••••}';
+		
+		/*
+		 * Used to indicate a new object was added
+		 * English: new %1$s
+		 * %1$s: the type of object
+		 */
+		$this->resources['new %1$s'] = '{*%1$s* nēw•••}';
+		
+		/*
+		 * Used to indicate an object was deleted
+		 * English: Deleted %1$s
+		 * %1$s: the type of object
+		 */
+		$this->resources['deleted %1$s'] = '{*%1$s* dĕlętēd•••}';
+		
+		
+		/*
+		 * Age strings
+		 *
+		 * These are used when formatting the age
+		 * (how long ago a project was modified) into
+		 * a human readable string
+		 */
+		
+		/*
+		 * Used to represent an age in years
+		 * English: %1$d years ago
+		 * %1$d: the number of years
+		 */
+		$this->resources['%1$d years ago'] = '{yęărs: *%1$d*•••}';
+		
+		/*
+		 * Used to represent an age in months
+		 * English: %1$d months ago
+		 * %1$d: the number of months
+		 */
+		$this->resources['%1$d months ago'] = '{mōnths: *%1$d*•••}';
+		
+		/*
+		 * Used to represent an age in weeks
+		 * English: %1$d weeks ago
+		 * %1$d: the number of weeks
+		 */
+		$this->resources['%1$d weeks ago'] = '{wěēks: *%1$d*•••}';
+		
+		/*
+		 * Used to represent an age in days
+		 * English: %1$d days ago
+		 * %1$d: the number of days
+		 */
+		$this->resources['%1$d days ago'] = '{dāys: *%1$d*••}';
+		
+		/*
+		 * Used to represent an age in hours
+		 * English: %1$d hours ago
+		 * %1$d: the number of hours
+		 */
+		$this->resources['%1$d hours ago'] = '{hőůrs: *%1$d*•••}';
+		
+		/*
+		 * Used to represent an age in minutes
+		 * English: %1$d min ago
+		 * %1$d: the number of minutes
+		 */
+		$this->resources['%1$d min ago'] = '{mĭnũtęs: *%1$d*•••}';
+		
+		/*
+		 * Used to represent an age in seconds
+		 * English: %1$d sec ago
+		 * %1$d: the number of seconds
+		 */
+		$this->resources['%1$d sec ago'] = '{sĕcōnds: *%1$d*•••}';
+		
+		/*
+		 * Used to represent a modification time of right now
+		 * English: right now
+		 */
+		$this->resources['right now'] = '{thıs ĩnstąnt}';
+
+
+		/*
+		 * Project list headers
+		 *
+		 * These are used as the headers for columns on the
+		 * home project list view
+		 */
+		 
+		/*
+		 * Used as the header for the project name column
+		 * English: Project
+		 */
+		$this->resources['Project_Header'] = '{Prŏjěct••}';
+		
+		/*
+		 * Used as the header for the project description column
+		 * English: Description
+		 */
+		$this->resources['Description_Header'] = '{Dėscrīptĭŏn••••}';
+		
+		/*
+		 * Used as the header for the column showing the person
+		 * that owns the project
+		 * English: Owner
+		 */
+		$this->resources['Owner_Header'] = '{Ŏwnēr••}';
+		
+		/*
+		 * Used as the header for the last change column
+		 * (how long ago was the last commit)
+		 * English: Last Change
+		 */
+		$this->resources['Last Change_Header'] = '{Låst Chángè•••}';
+		
+		/*
+		 * Used as the header for the actions column, which is
+		 * a list of links users can use to jump to various parts
+		 * of this project
+		 * English: Actions
+		 */
+		$this->resources['Actions_Header'] = '{Åctĩøns••}';
+	}
+
+}
+

--- a/include/smartyplugins/modifier.agestring.php
+++ b/include/smartyplugins/modifier.agestring.php
@@ -10,20 +10,20 @@
 function smarty_modifier_agestring($age)
 {
 	if ($age > 60*60*24*365*2)
-		return (int)($age/60/60/24/365) . " years ago";
+		return sprintf(GitPHP_Resource::GetInstance()->GetResource('%1$d years ago'), (int)($age/60/60/24/365));
 	else if ($age > 60*60*24*(365/12)*2)
-		return (int)($age/60/60/24/(365/12)) . " months ago";
+		return sprintf(GitPHP_Resource::GetInstance()->GetResource('%1$d months ago'), (int)($age/60/60/24/(365/12)));
 	else if ($age > 60*60*24*7*2)
-		return (int)($age/60/60/24/7) . " weeks ago";
+		return sprintf(GitPHP_Resource::GetInstance()->GetResource('%1$d weeks ago'), (int)($age/60/60/24/7));
 	else if ($age > 60*60*24*2)
-		return (int)($age/60/60/24) . " days ago";
+		return sprintf(GitPHP_Resource::GetInstance()->GetResource('%1$d days ago'), (int)($age/60/60/24));
 	else if ($age > 60*60*2)
-		return (int)($age/60/60) . " hours ago";
+		return sprintf(GitPHP_Resource::GetInstance()->GetResource('%1$d hours ago'), (int)($age/60/60));
 	else if ($age > 60*2)
-		return (int)($age/60) . " min ago";
+		return sprintf(GitPHP_Resource::GetInstance()->GetResource('%1$d min ago'), (int)($age/60));
 	else if ($age > 2)
-		return (int)$age . " sec ago";
-	return "right now";
+		return sprintf(GitPHP_Resource::GetInstance()->GetResource('%1$d sec ago'), (int)$age);
+	return GitPHP_Resource::GetInstance()->GetResource('right now');
 }
 
 ?>

file:a/index.php -> file:b/index.php
--- a/index.php
+++ b/index.php
@@ -20,10 +20,14 @@
 define('GITPHP_INCLUDEDIR', GITPHP_BASEDIR . 'include/');
 define('GITPHP_GITOBJECTDIR', GITPHP_INCLUDEDIR . 'git/');
 define('GITPHP_CONTROLLERDIR', GITPHP_INCLUDEDIR . 'controller/');
+define('GITPHP_RESOURCEDIR', GITPHP_INCLUDEDIR . 'resource/');
+define('GITPHP_LOCALEDIR', GITPHP_RESOURCEDIR . 'locale/');
 
 include_once(GITPHP_INCLUDEDIR . 'version.php');
 
 require_once(GITPHP_INCLUDEDIR . 'Config.class.php');
+
+require_once(GITPHP_RESOURCEDIR . 'Resource.class.php');
 
 require_once(GITPHP_INCLUDEDIR . 'Log.class.php');
 
@@ -46,6 +50,11 @@
 	 * Configuration
 	 */
 	GitPHP_Config::GetInstance()->LoadConfig(GITPHP_CONFIGDIR . 'gitphp.conf.php');
+
+	/*
+	 * Resource
+	 */
+	GitPHP_Resource::Instantiate(GitPHP_Config::GetInstance()->GetValue('locale', 'en_US'));
 
 	/*
 	 * Debug

--- a/templates/blame.tpl
+++ b/templates/blame.tpl
@@ -9,7 +9,7 @@
  {include file='header.tpl'}
 
  <div class="page_nav">
-   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">summary</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">tree</a><br />
+   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">{$resources->GetResource('tree')}</a><br />
    <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob_plain&h={$blob->GetHash()}&f={$blob->GetPath()}">plain</a> | 
    {if $commit->GetHash() != $head->GetHash()}
      <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blame&hb=HEAD&f={$blob->GetPath()}">HEAD</a>

--- a/templates/blob.tpl
+++ b/templates/blob.tpl
@@ -9,14 +9,14 @@
  {include file='header.tpl'}
 
  <div class="page_nav">
-   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">summary</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">tree</a><br />
+   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">{$resources->GetResource('tree')}</a><br />
    <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob_plain&h={$blob->GetHash()}&f={$blob->GetPath()}">plain</a> | 
    {if ($commit->GetHash() != $head->GetHash()) && ($head->PathToHash($blob->GetPath()))}
      <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&hb=HEAD&f={$blob->GetPath()}">HEAD</a>
    {else}
      HEAD
    {/if}
-   {if !$datatag} | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blame&h={$blob->GetHash()}&f={$blob->GetPath()}&hb={$commit->GetHash()}" id="blameLink">blame</a>{/if}
+   {if !$datatag} | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blame&h={$blob->GetHash()}&f={$blob->GetPath()}&hb={$commit->GetHash()}" id="blameLink">{$resources->GetResource('blame')}</a>{/if}
    <br />
  </div>
 

--- a/templates/blobdiff.tpl
+++ b/templates/blobdiff.tpl
@@ -10,7 +10,7 @@
 
  {* If we managed to look up commit info, we have enough info to display the full header - othewise just use a simple header *}
  <div class="page_nav">
-   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">summary</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">tree</a>
+   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">{$resources->GetResource('tree')}</a>
    <br />
    <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blobdiff_plain&h={$blob->GetHash()}&hp={$blobparent->GetHash()}&f={$file}">plain</a>
  </div>
@@ -22,7 +22,7 @@
  <div class="page_body">
    <div class="diff_info">
      {* Display the from -> to diff header *}
-     blob:<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$blobparent->GetHash()}&hb={$commit->GetHash()}&f={$file}">{if $file}a/{$file}{else}{$blobparent->GetHash()}{/if}</a> -&gt; blob:<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$blob->GetHash()}&hb={$commit->GetHash()}&f={$file}">{if $file}b/{$file}{else}{$blob->GetHash()}{/if}</a>
+     {$resources->GetResource('blob')}:<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$blobparent->GetHash()}&hb={$commit->GetHash()}&f={$file}">{if $file}a/{$file}{else}{$blobparent->GetHash()}{/if}</a> -&gt; {$resources->GetResource('blob')}:<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$blob->GetHash()}&hb={$commit->GetHash()}&f={$file}">{if $file}b/{$file}{else}{$blob->GetHash()}{/if}</a>
    </div>
    {* Display the diff *}
    {include file='filediff.tpl' diff=$filediff->GetDiff($file, false, true)}

--- a/templates/commit.tpl
+++ b/templates/commit.tpl
@@ -10,7 +10,7 @@
 
  <div class="page_nav">
    {* Nav *}
-   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">summary</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h={$commit->GetHash()}">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h={$commit->GetHash()}">log</a> | commit | {if $commit->GetParent()}<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">commitdiff</a> | {/if}<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">tree</a>
+   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h={$commit->GetHash()}">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h={$commit->GetHash()}">{$resources->GetResource('log')}</a> | {$resources->GetResource('commit')} | {if $commit->GetParent()}<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">{$resources->GetResource('commitdiff')}</a> | {/if}<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">{$resources->GetResource('tree')}</a>
    <br /><br />
  </div>
 
@@ -24,7 +24,7 @@
    {* Commit data *}
    <table cellspacing="0">
      <tr>
-       <td>author</td>
+       <td>{$resources->GetResource('author')}</td>
        <td>{$commit->GetAuthorName()}</td>
      </tr>
      <tr>
@@ -38,7 +38,7 @@
        {/if}
      </tr>
      <tr>
-       <td>committer</td>
+       <td>{$resources->GetResource('committer')}</td>
        <td>{$commit->GetCommitterName()}</td>
      </tr>
      <tr>
@@ -46,19 +46,19 @@
        <td> {$commit->GetCommitterEpoch()|date_format:"%a, %d %b %Y %H:%M:%S %z"} ({$commit->GetCommitterLocalEpoch()|date_format:"%R"} {$commit->GetCommitterTimezone()})</td>
      </tr>
      <tr>
-       <td>commit</td>
+       <td>{$resources->GetResource('commit')}</td>
        <td class="monospace">{$commit->GetHash()}</td>
      <tr>
      <tr>
-       <td>tree</td>
+       <td>{$resources->GetResource('tree')}</td>
        <td class="monospace"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}" class="list">{$tree->GetHash()}</a></td>
-       <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">tree</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=snapshot&h={$commit->GetHash()}">snapshot</a></td>
+       <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">{$resources->GetResource('tree')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=snapshot&h={$commit->GetHash()}">{$resources->GetResource('snapshot')}</a></td>
      </tr>
      {foreach from=$commit->GetParents() item=par}
        <tr>
-         <td>parent</td>
+         <td>{$resources->GetResource('parent')}</td>
 	 <td class="monospace"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$par->GetHash()}" class="list">{$par->GetHash()}</a></td>
-         <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$par->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}&hp={$par->GetHash()}">commitdiff</a></td>
+         <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$par->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}&hp={$par->GetHash()}">{$resources->GetResource('commitdiff')}</a></td>
        </tr>
      {/foreach}
    </table>
@@ -70,7 +70,7 @@
  </div>
  <div class="list_head">
    {if $treediff->Count() > 10}
-     {$treediff->Count()} files changed:
+     {$resources->Format('%1$d files changed:', $treediff->Count())}
    {/if}
  </div>
  <table cellspacing="0">
@@ -86,17 +86,18 @@
 	 </td>
          <td>
 	   <span class="newfile">
+	     {assign var=localtotype value=$resources->GetResource($diffline->GetToFileType())}
 	     [
 	     {if $diffline->ToFileIsRegular()}
-	     new {$diffline->GetToFileType()} with mode: {$diffline->GetToModeShort()}
+	     {$resources->Format('new %1$s with mode %2$s', $localtotype, $diffline->GetToModeShort())}
 	     {else}
-	     new {$diffline->GetToFileType()}
+	     {$resources->Format('new %1$s', $localtotype)}
 	     {/if}
 	     ]
 	   </span>
 	 </td>
          <td class="link">
-	   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$diffline->GetToHash()}&hb={$commit->GetHash()}&f={$diffline->GetFromFile()}">blob</a>
+	   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$diffline->GetToHash()}&hb={$commit->GetHash()}&f={$diffline->GetFromFile()}">{$resources->GetResource('blob')}</a>
 	 </td>
        {elseif $diffline->GetStatus() == "D"}
          <td>
@@ -106,11 +107,12 @@
 	 </td>
          <td>
 	   <span class="deletedfile">
-	     [ deleted {$diffline->GetFromFileType()} ]
+	     {assign var=localfromtype value=$resources->GetResource($diffline->GetFromFileType())}
+	     [ {$resources->Format('deleted %1$s', $localfromtype)} ]
 	   </span>
 	 </td>
          <td class="link">
-	   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$diffline->GetFromHash()}&hb={$commit->GetHash()}&f={$diffline->GetFromFile()}">blob</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=history&h={$commit->GetHash()}&f={$diffline->GetFromFile()}">history</a>
+	   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$diffline->GetFromHash()}&hb={$commit->GetHash()}&f={$diffline->GetFromFile()}">{$resources->GetResource('blob')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=history&h={$commit->GetHash()}&f={$diffline->GetFromFile()}">{$resources->GetResource('history')}</a>
 	 </td>
        {elseif $diffline->GetStatus() == "M" || $diffline->GetStatus() == "T"}
          <td>
@@ -158,11 +160,11 @@
 	   {/if}
 	 </td>
          <td class="link">
-           <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$diffline->GetToHash()}&hb={$commit->GetHash()}&f={$diffline->GetToFile()}">blob</a>
+           <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$diffline->GetToHash()}&hb={$commit->GetHash()}&f={$diffline->GetToFile()}">{$resources->GetResource('blob')}</a>
 	   {if $diffline->GetToHash() != $diffline->GetFromHash()}
-	     | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blobdiff&h={$diffline->GetToHash()}&hp={$diffline->GetFromHash()}&hb={$commit->GetHash()}&f={$diffline->GetToFile()}">diff</a>
+	     | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blobdiff&h={$diffline->GetToHash()}&hp={$diffline->GetFromHash()}&hb={$commit->GetHash()}&f={$diffline->GetToFile()}">{$resources->GetResource('diff')}</a>
 	   {/if}
-	     | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=history&h={$commit->GetHash()}&f={$diffline->GetFromFile()}">history</a>
+	     | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=history&h={$commit->GetHash()}&f={$diffline->GetFromFile()}">{$resources->GetResource('history')}</a>
 	 </td>
        {elseif $diffline->GetStatus() == "R"}
          <td>
@@ -181,9 +183,9 @@
 	   </span>
 	 </td>
          <td class="link">
-	   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$diffline->GetToHash()}&hb={$commit->GetHash()}&f={$diffline->GetToFile()}">blob</a>
+	   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$diffline->GetToHash()}&hb={$commit->GetHash()}&f={$diffline->GetToFile()}">{$resources->GetResource('blob')}</a>
 	   {if $diffline->GetToHash() != $diffline->GetFromHash()}
-	     | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blobdiff&h={$diffline->GetToHash()}&hp={$diffline->GetFromHash()}&hb={$commit->GetHash()}&f={$diffline->GetToFile()}">diff</a>
+	     | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blobdiff&h={$diffline->GetToHash()}&hp={$diffline->GetFromHash()}&hb={$commit->GetHash()}&f={$diffline->GetToFile()}">{$resources->GetResource('diff')}</a>
 	   {/if}
 	 </td>
        {/if}

--- a/templates/commitdiff.tpl
+++ b/templates/commitdiff.tpl
@@ -11,7 +11,7 @@
  {* Nav *}
  <div class="page_nav">
    {assign var=tree value=$commit->GetTree()}
-   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">summary</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h={$commit->GetHash()}">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h={$commit->GetHash()}">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">commit</a> | commitdiff | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">tree</a><br /><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff_plain&h={$commit->GetHash()}{if $hashparent}&hp={$hashparent}{/if}">plain</a>
+   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h={$commit->GetHash()}">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h={$commit->GetHash()}">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">{$resources->GetResource('commit')}</a> | {$resources->GetResource('commitdiff')} | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">{$resources->GetResource('tree')}</a><br /><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff_plain&h={$commit->GetHash()}{if $hashparent}&hp={$hashparent}{/if}">plain</a>
  </div>
 
  {include file='title.tpl' titlecommit=$commit}

--- a/templates/header.tpl
+++ b/templates/header.tpl
@@ -40,11 +40,11 @@
       <a href="http://git-scm.com" title="git homepage">
         <img src="images/git-logo.png" width="72" height="27" alt="git" class="logo" />
       </a>
-      <a href="index.php">projects</a> / 
+      <a href="index.php">{$resources->GetResource('projects')}</a> / 
       {if $project}
         <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$project->GetProject()}</a>
         {if $action}
-           / {$action}
+           / {$resources->GetResource($action)}
         {/if}
         {if $enablesearch}
           <form method="get" action="index.php" enctype="application/x-www-form-urlencoded">
@@ -53,13 +53,13 @@
               <input type="hidden" name="a" value="search" />
               <input type ="hidden" name="h" value="{if $commit}{$commit->GetHash()}{else}HEAD{/if}" />
               <select name="st">
-                <option {if $searchtype == 'commit'}selected="selected"{/if} value="commit">commit</option>
-                <option {if $searchtype == 'author'}selected="selected"{/if} value="author">author</option>
-                <option {if $searchtype == 'committer'}selected="selected"{/if} value="committer">committer</option>
+                <option {if $searchtype == 'commit'}selected="selected"{/if} value="commit">{$resources->GetResource('commit')}</option>
+                <option {if $searchtype == 'author'}selected="selected"{/if} value="author">{$resources->GetResource('author')}</option>
+                <option {if $searchtype == 'committer'}selected="selected"{/if} value="committer">{$resources->GetResource('committer')}</option>
                 {if $filesearch}
-                  <option {if $searchtype == 'file'}selected="selected"{/if} value="file">file</option>
+                  <option {if $searchtype == 'file'}selected="selected"{/if} value="file">{$resources->GetResource('file')}</option>
                 {/if}
-              </select> search: <input type="text" name="s" {if $search}value="{$search}"{/if} />
+              </select> {$resources->GetResource('search')}: <input type="text" name="s" {if $search}value="{$search}"{/if} />
             </div>
           </form>
         {/if}

--- a/templates/heads.tpl
+++ b/templates/heads.tpl
@@ -10,7 +10,7 @@
 
  {* Nav *}
  <div class="page_nav">
-   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">summary</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$head}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$head}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&hb={$head}">tree</a>
+   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$head}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$head}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&hb={$head}">{$resources->GetResource('tree')}</a>
    <br /><br />
  </div>
 
@@ -23,7 +23,7 @@
      <tr class="{cycle values="light,dark"}">
        <td><em>{$headcommit->GetAge()|agestring}</em></td>
        <td><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h=refs/heads/{$head->GetName()}" class="list"><strong>{$head->GetName()}</strong></a></td>
-       <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h=refs/heads/{$head->GetName()}">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h=refs/heads/{$head->GetName()}">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h=refs/heads/{$head->GetName()}&hb={$headcommit->GetHash()}">tree</a></td>
+       <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h=refs/heads/{$head->GetName()}">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h=refs/heads/{$head->GetName()}">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h=refs/heads/{$head->GetName()}&hb={$headcommit->GetHash()}">{$resources->GetResource('tree')}</a></td>
      </tr>
    {/foreach}
  </table>

--- a/templates/history.tpl
+++ b/templates/history.tpl
@@ -10,7 +10,7 @@
 
  {* Page header *}
  <div class="page_nav">
-   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">summary</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">tree</a>
+   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">{$resources->GetResource('tree')}</a>
    <br /><br />
  </div>
 
@@ -39,7 +39,7 @@
        {/foreach}
        </span>
        </td>
-       <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$historycommit->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$historycommit->GetHash()}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&hb={$historycommit->GetHash()}&f={$blob->GetPath()}">blob</a>{if $blob->GetHash() != $historyitem->GetToHash()} | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blobdiff&h={$blob->GetHash()}&hp={$historyitem->GetToHash()}&hb={$historycommit->GetHash()}&f={$blob->GetPath()}">diff to current</a>{/if}
+       <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$historycommit->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$historycommit->GetHash()}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&hb={$historycommit->GetHash()}&f={$blob->GetPath()}">{$resources->GetResource('blob')}</a>{if $blob->GetHash() != $historyitem->GetToHash()} | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blobdiff&h={$blob->GetHash()}&hp={$historyitem->GetToHash()}&hb={$historycommit->GetHash()}&f={$blob->GetPath()}">{$resources->GetResource('diff to current')}</a>{/if}
        </td>
      </tr>
    {/foreach}

--- a/templates/log.tpl
+++ b/templates/log.tpl
@@ -10,7 +10,7 @@
 
  {* Nav *}
  <div class="page_nav">
-   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">summary</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h={$commit->GetHash()}">shortlog</a> | log | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$commit->GetHash()}&hb={$commit->GetHash()}">tree</a>
+   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h={$commit->GetHash()}">{$resources->GetResource('shortlog')}</a> | {$resources->GetResource('log')} | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$commit->GetHash()}&hb={$commit->GetHash()}">{$resources->GetResource('tree')}</a>
    <br />
    {if ($commit->GetHash() != $head->GetHash()) || ($page > 0)}
      <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">HEAD</a>
@@ -49,7 +49,7 @@
    </div>
    <div class="title_text">
      <div class="log_link">
-       <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$rev->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$rev->GetHash()}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$rev->GetHash()}&hb={$rev->GetHash()}">tree</a>
+       <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$rev->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$rev->GetHash()}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$rev->GetHash()}&hb={$rev->GetHash()}">{$resources->GetResource('tree')}</a>
        <br />
      </div>
      <em>{$rev->GetAuthorName()} [{$rev->GetAuthorEpoch()|date_format:"%a, %d %b %Y %H:%M:%S %z"}]</em><br />

--- a/templates/project.tpl
+++ b/templates/project.tpl
@@ -10,7 +10,7 @@
 
  {* Nav *}
  <div class="page_nav">
-   summary | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$head->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$head->GetHash()}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree">tree</a>
+   {$resources->GetResource('summary')} | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$head->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$head->GetHash()}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree">{$resources->GetResource('tree')}</a>
    <br /><br />
  </div>
 
@@ -18,14 +18,14 @@
 
  {* Project brief *}
  <table cellspacing="0">
-   <tr><td>description</td><td>{$project->GetDescription()}</td></tr>
-   <tr><td>owner</td><td>{$project->GetOwner()}</td></tr>
-   <tr><td>last change</td><td>{$head->GetCommitterEpoch()|date_format:"%a, %d %b %Y %H:%M:%S %z"}</td></tr>
+   <tr><td>{$resources->GetResource('description')}</td><td>{$project->GetDescription()}</td></tr>
+   <tr><td>{$resources->GetResource('owner')}</td><td>{$project->GetOwner()}</td></tr>
+   <tr><td>{$resources->GetResource('last change')}</td><td>{$head->GetCommitterEpoch()|date_format:"%a, %d %b %Y %H:%M:%S %z"}</td></tr>
    {if $project->GetCloneUrl()}
-     <tr><td>clone url</td><td>{$project->GetCloneUrl()}</td></tr>
+     <tr><td>{$resources->GetResource('clone url')}</td><td>{$project->GetCloneUrl()}</td></tr>
    {/if}
    {if $project->GetPushUrl()}
-     <tr><td>push url</td><td>{$project->GetPushUrl()}</td></tr>
+     <tr><td>{$resources->GetResource('push url')}</td><td>{$project->GetPushUrl()}</td></tr>
    {/if}
  </table>
 
@@ -51,7 +51,7 @@
        {/foreach}
        </span>
      </td>
-     <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$rev->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$rev->GetHash()}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$rev->GetHash()}&hb={$rev->GetHash()}">tree</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=snapshot&h={$rev->GetHash()}">snapshot</a></td>
+     <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$rev->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$rev->GetHash()}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$rev->GetHash()}&hb={$rev->GetHash()}">{$resources->GetResource('tree')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=snapshot&h={$rev->GetHash()}">{$resources->GetResource('snapshot')}</a></td>
      </tr>
    {/foreach}
    {if $hasmorerevs}
@@ -72,8 +72,9 @@
            <td><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tags">...</a></td>
          {else}
 	   {assign var=object value=$taglist[tag]->GetObject()}
+	   {assign var=objtype value=$taglist[tag]->GetType()}
            <td><em>{$object->GetAge()|agestring}</em></td>
-           <td><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a={$taglist[tag]->GetType()}&h={$object->GetHash()}" class="list"><strong>{$taglist[tag]->GetName()}</strong></a></td>
+           <td><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a={$objtype}&h={$object->GetHash()}" class="list"><strong>{$taglist[tag]->GetName()}</strong></a></td>
            <td>
 	     {assign var=comment value=$taglist[tag]->GetComment()}
              {if count($comment) > 0}
@@ -82,11 +83,11 @@
            </td>
            <td class="link">
              {if !$taglist[tag]->LightTag()}
-   	       <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tag&h={$taglist[tag]->GetName()}">tag</a> | 
+   	       <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tag&h={$taglist[tag]->GetName()}">{$resources->GetResource('tag')}</a> | 
              {/if}
-             <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a={$taglist[tag]->GetType()}&h={$taglist[tag]->GetHash()}">{$taglist[tag]->GetType()}</a>
-	     {if $taglist[tag]->GetType() == "commit"}
-	      | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h=refs/tags/{$taglist[tag]->GetName()}">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h=refs/tags/{$taglist[tag]->GetName()}">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=snapshot&h={$object->GetHash()}">snapshot</a>{/if}
+             <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a={$objtype}&h={$object->GetHash()}">{$resources->GetResource($objtype)}</a>
+	     {if $objtype == "commit"}
+	      | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h=refs/tags/{$taglist[tag]->GetName()}">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h=refs/tags/{$taglist[tag]->GetName()}">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=snapshot&h={$object->GetHash()}">{$resources->GetResource('snapshot')}</a>{/if}
            </td>
          {/if}
        </tr>
@@ -107,7 +108,7 @@
 	   {assign var=headcommit value=$headlist[head]->GetCommit()}
            <td><em>{$headcommit->GetAge()|agestring}</em></td>
            <td><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h=refs/heads/{$headlist[head]->GetName()}" class="list"><strong>{$headlist[head]->GetName()}</strong></td>
-           <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h=refs/heads/{$headlist[head]->GetName()}">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h=refs/heads/{$headlist[head]->GetName()}">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h=refs/heads/{$headlist[head]->GetName()}&hb={$headcommit->GetHash()}">tree</a></td>
+           <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h=refs/heads/{$headlist[head]->GetName()}">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h=refs/heads/{$headlist[head]->GetName()}">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h=refs/heads/{$headlist[head]->GetName()}&hb={$headcommit->GetHash()}">{$resources->GetResource('tree')}</a></td>
          {/if}
        </tr>
      {/section}

--- a/templates/projectlist.tpl
+++ b/templates/projectlist.tpl
@@ -16,26 +16,26 @@
       {* Header *}
       <tr>
         {if $order == "project"}
-          <th>Project</th>
+          <th>{$resources->GetResource('Project', 'Header')}</th>
         {else}
-          <th><a class="header" href="{$SCRIPT_NAME}?o=project">Project</a></th>
+          <th><a class="header" href="{$SCRIPT_NAME}?o=project">{$resources->GetResource('Project', 'Header')}</a></th>
         {/if}
         {if $order == "descr"}
-          <th>Description</th>
+          <th>{$resources->GetResource('Description', 'Header')}</th>
         {else}
-          <th><a class="header" href="{$SCRIPT_NAME}?o=descr">Description</a></th>
+          <th><a class="header" href="{$SCRIPT_NAME}?o=descr">{$resources->GetResource('Description', 'Header')}</a></th>
         {/if}
         {if $order == "owner"}
-          <th>Owner</th>
+          <th>{$resources->GetResource('Owner', 'Header')}</th>
         {else}
-          <th><a class="header" href="{$SCRIPT_NAME}?o=owner">Owner</a></th>
+          <th><a class="header" href="{$SCRIPT_NAME}?o=owner">{$resources->GetResource('Owner', 'Header')}</a></th>
         {/if}
         {if $order == "age"}
-          <th>Last Change</th>
+          <th>{$resources->GetResource('Last Change', 'Header')}</th>
         {else}
-          <th><a class="header" href="{$SCRIPT_NAME}?o=age">Last Change</a></th>
+          <th><a class="header" href="{$SCRIPT_NAME}?o=age">{$resources->GetResource('Last Change', 'Header')}</a></th>
         {/if}
-        <th>Actions</th>
+        <th>{$resources->GetResource('Actions', 'Header')}</th>
       </tr>
     {/if}
 
@@ -69,11 +69,11 @@
         {/if}
       </td>
       <td class="link">
-        <a href="{$SCRIPT_NAME}?p={$proj->GetProject()|urlencode}&a=summary">summary</a> | 
-	<a href="{$SCRIPT_NAME}?p={$proj->GetProject()|urlencode}&a=shortlog">shortlog</a> | 
-	<a href="{$SCRIPT_NAME}?p={$proj->GetProject()|urlencode}&a=log">log</a> | 
-	<a href="{$SCRIPT_NAME}?p={$proj->GetProject()|urlencode}&a=tree">tree</a> | 
-	<a href="{$SCRIPT_NAME}?p={$proj->GetProject()|urlencode}&a=snapshot&h=HEAD">snapshot</a>
+        <a href="{$SCRIPT_NAME}?p={$proj->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | 
+	<a href="{$SCRIPT_NAME}?p={$proj->GetProject()|urlencode}&a=shortlog">{$resources->GetResource('shortlog')}</a> | 
+	<a href="{$SCRIPT_NAME}?p={$proj->GetProject()|urlencode}&a=log">{$resources->GetResource('log')}</a> | 
+	<a href="{$SCRIPT_NAME}?p={$proj->GetProject()|urlencode}&a=tree">{$resources->GetResource('tree')}</a> | 
+	<a href="{$SCRIPT_NAME}?p={$proj->GetProject()|urlencode}&a=snapshot&h=HEAD">{$resources->GetResource('snapshot')}</a>
       </td>
     </tr>
   {foreachelse}

--- a/templates/search.tpl
+++ b/templates/search.tpl
@@ -10,7 +10,7 @@
 
 {* Nav *}
 <div class="page_nav">
-  <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">summary</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h={$commit->GetHash()}">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h={$commit->GetHash()}">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">tree</a>
+  <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h={$commit->GetHash()}">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h={$commit->GetHash()}">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">{$resources->GetResource('tree')}</a>
   <br />
   {if $page > 0}
     <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=search&h={$commit->GetHash()}&s={$search}&st={$searchtype}">first</a>
@@ -58,7 +58,7 @@
       {/if}
       </td>
       {assign var=resulttree value=$result->GetTree()}
-      <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$result->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$result->GetHash()}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$resulttree->GetHash()}&hb={$result->GetHash()}">tree</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=snapshot&h={$result->GetHash()}">snapshot</a>
+      <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$result->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$result->GetHash()}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$resulttree->GetHash()}&hb={$result->GetHash()}">{$resources->GetResource('tree')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=snapshot&h={$result->GetHash()}">{$resources->GetResource('snapshot')}</a>
       </td>
     </tr>
   {/foreach}

--- a/templates/searchfiles.tpl
+++ b/templates/searchfiles.tpl
@@ -10,7 +10,7 @@
 
 {* Nav *}
 <div class="page_nav">
-  <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">summary</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h={$commit->GetHash()}">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h={$commit->GetHash()}">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">tree</a>
+  <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h={$commit->GetHash()}">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h={$commit->GetHash()}">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$tree->GetHash()}&hb={$commit->GetHash()}">{$resources->GetResource('tree')}</a>
   <br />
   {if $page > 0}
     <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=search&h={$commit->GetHash()}&s={$search}&st={$searchtype}">first</a>
@@ -44,7 +44,7 @@
 		  <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$resultobject->GetHash()}&hb={$commit->GetHash()}&f={$path}" class="list"><strong>{$path}</strong></a>
 	      </td>
 	      <td class="link">
-		  <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$resultobject->GetHash()}&hb={$commit->GetHash()}&f={$path}">tree</a>
+		  <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$resultobject->GetHash()}&hb={$commit->GetHash()}&f={$path}">{$resources->GetResource('tree')}</a>
 	      </td>
       {else}
 	      <td>
@@ -54,7 +54,7 @@
 		  {/foreach}
 	      </td>
 	      <td class="link">
-		  <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$resultobject->GetHash()}&hb={$commit->GetHash()}&f={$path}">blob</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=history&h={$commit->GetHash()}&f={$path}">history</a>
+		  <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$resultobject->GetHash()}&hb={$commit->GetHash()}&f={$path}">{$resources->GetResource('blob')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=history&h={$commit->GetHash()}&f={$path}">{$resources->GetResource('history')}</a>
 	      </td>
       {/if}
     </tr>

--- a/templates/shortlog.tpl
+++ b/templates/shortlog.tpl
@@ -10,7 +10,7 @@
 
  {* Nav *}
  <div class="page_nav">
-   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">summary</a> | shortlog | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h={$commit->GetHash()}">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$commit->GetHash()}&hb={$commit->GetHash()}">tree</a>
+   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | {$resources->GetResource('shortlog')} | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h={$commit->GetHash()}">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$commit->GetHash()}&hb={$commit->GetHash()}">{$resources->GetResource('tree')}</a>
    <br />
    {if ($commit->GetHash() != $head->GetHash()) || ($page > 0)}
      <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">HEAD</a>
@@ -54,7 +54,7 @@
 	 {/foreach}
 	 </span>
        </td>
-       <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$rev->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$rev->GetHash()}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$rev->GetHash()}&hb={$rev->GetHash()}">tree</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=snapshot&h={$rev->GetHash()}">snapshot</a>
+       <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$rev->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$rev->GetHash()}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$rev->GetHash()}&hb={$rev->GetHash()}">{$resources->GetResource('tree')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=snapshot&h={$rev->GetHash()}">{$resources->GetResource('snapshot')}</a>
        </td>
      </tr>
    {/foreach}

--- a/templates/tag.tpl
+++ b/templates/tag.tpl
@@ -10,11 +10,12 @@
 
  {* Nav *}
  <div class="page_nav">
-   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">summary</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$head}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$head}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&hb={$head}">tree</a>
+   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$head}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$head}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&hb={$head}">{$resources->GetResource('tree')}</a>
    <br /><br />
  </div>
  {* Tag data *}
  {assign var=object value=$tag->GetObject()}
+ {assign var=objtype value=$tag->GetType()}
  <div class="title">
    <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$object->GetHash()}" class="title">{$tag->GetName()}</a>
  </div>
@@ -22,8 +23,8 @@
    <table cellspacing="0">
      <tr>
        <td>object</td>
-       <td class="monospace"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a={$tag->GetType()}&h={$object->GetHash()}" class="list">{$object->GetHash()}</a></td>
-       <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a={$tag->GetType()}&h={$object->GetHash()}">{$tag->GetType()}</a></td>
+       <td class="monospace"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a={$objtype}&h={$object->GetHash()}" class="list">{$object->GetHash()}</a></td>
+       <td class="link"><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a={$objtype}&h={$object->GetHash()}">{$resources->GetResource($objtype)}</a></td>
      </tr>
      {if $tag->GetTagger()}
        <tr>

--- a/templates/tags.tpl
+++ b/templates/tags.tpl
@@ -10,7 +10,7 @@
 
  {* Nav *}
  <div class="page_nav">
-   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">summary</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$head}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$head}">commitdiff</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&hb={$head}">tree</a>
+   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$head}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$head}">{$resources->GetResource('commitdiff')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&hb={$head}">{$resources->GetResource('tree')}</a>
    <br /><br />
  </div>
 
@@ -20,9 +20,10 @@
  <table cellspacing="0">
    {foreach name=tags from=$taglist item=tag}
      {assign var=object value=$tag->GetObject()}
+     {assign var=objtype value=$tag->GetType()}
      <tr class="{cycle values="light,dark"}">
        <td><em>{$object->GetAge()|agestring}</em></td>
-       <td><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a={$tag->GetType()}&h={$object->GetHash()}" class="list"><strong>{$tag->GetName()}</strong></a></td>
+       <td><a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a={$objtype}&h={$object->GetHash()}" class="list"><strong>{$tag->GetName()}</strong></a></td>
        <td>
          {assign var=comment value=$tag->GetComment()}
          {if count($comment) > 0}
@@ -31,11 +32,11 @@
        </td>
        <td class="link">
          {if !$tag->LightTag()}
-	   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tag&h={$tag->GetName()}">tag</a> | 
+	   <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tag&h={$tag->GetName()}">{$resources->GetResource('tag')}</a> | 
 	 {/if}
-	 <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a={$tag->GetType()}&h={$object->GetHash()}">{$tag->GetType()}</a>
-	 {if $tag->GetType() == "commit"}
-	   | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h=refs/tags/{$tag->GetName()}">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h=refs/tags/{$tag->GetName()}">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=snapshot&h={$object->GetHash()}">snapshot</a>
+	 <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a={$objtype}&h={$object->GetHash()}">{$resources->GetResource($objtype)}</a>
+	 {if $objtype == "commit"}
+	   | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h=refs/tags/{$tag->GetName()}">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h=refs/tags/{$tag->GetName()}">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=snapshot&h={$object->GetHash()}">{$resources->GetResource('snapshot')}</a>
 	 {/if}
        </td>
      </tr>

--- a/templates/title.tpl
+++ b/templates/title.tpl
@@ -34,11 +34,11 @@
 		{if $target == 'summary'}
 			<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary" class="title">&nbsp;</a>
 		{elseif $target == 'shortlog'}
-			<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog" class="title">shortlog</a>
+			<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog" class="title">{$resources->GetResource('shortlog')}</a>
 		{elseif $target == 'tags'}
-			<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tags" class="title">tags</a>
+			<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tags" class="title">{$resources->GetResource('tags')}</a>
 		{elseif $target == 'heads'}
-			<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=heads" class="title">heads</a>
+			<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=heads" class="title">{$resources->GetResource('heads')}</a>
 		{else}
 			&nbsp;
 		{/if}

--- a/templates/tree.tpl
+++ b/templates/tree.tpl
@@ -10,7 +10,7 @@
 
  {* Nav *}
    <div class="page_nav">
-     <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">summary</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h={$commit->GetHash()}">shortlog</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h={$commit->GetHash()}">log</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">commit</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">commitdiff</a> | tree<br /><br />
+     <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=summary">{$resources->GetResource('summary')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=shortlog&h={$commit->GetHash()}">{$resources->GetResource('shortlog')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=log&h={$commit->GetHash()}">{$resources->GetResource('log')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commit&h={$commit->GetHash()}">{$resources->GetResource('commit')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=commitdiff&h={$commit->GetHash()}">{$resources->GetResource('commitdiff')}</a> | {$resources->GetResource('tree')}<br /><br />
    </div>
 
  {include file='title.tpl' titlecommit=$commit}
@@ -29,7 +29,7 @@
              <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$treeitem->GetHash()}&hb={$commit->GetHash()}&f={$treeitem->GetPath()}" class="list">{$treeitem->GetName()}</a>
 	   </td>
            <td class="link">
-	     <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$treeitem->GetHash()}&hb={$commit->GetHash()}&f={$treeitem->GetPath()}">blob</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=history&h={$commit->GetHash()}&f={$treeitem->GetPath()}">history</a>
+	     <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$treeitem->GetHash()}&hb={$commit->GetHash()}&f={$treeitem->GetPath()}">{$resources->GetResource('blob')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=history&h={$commit->GetHash()}&f={$treeitem->GetPath()}">{$resources->GetResource('history')}</a>
 	   </td>
          {elseif $treeitem instanceof GitPHP_Tree}
 	   <td></td>
@@ -37,7 +37,7 @@
              <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$treeitem->GetHash()}&hb={$commit->GetHash()}&f={$treeitem->GetPath()}">{$treeitem->GetName()}</a>
 	   </td>
            <td class="link">
-	     <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$treeitem->GetHash()}&hb={$commit->GetHash()}&f={$treeitem->GetPath()}">tree</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=snapshot&h={$commit->GetHash()}&f={$treeitem->GetPath()}">snapshot</a>
+	     <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=tree&h={$treeitem->GetHash()}&hb={$commit->GetHash()}&f={$treeitem->GetPath()}">{$resources->GetResource('tree')}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=snapshot&h={$commit->GetHash()}&f={$treeitem->GetPath()}">{$resources->GetResource('snapshot')}</a>
 	   </td>
          {/if}
        </tr>

comments