r19175 - htdocs/trunk - Use http GET variable and cookie to handle language selection

Geert Janssens gjanssens at code.gnucash.org
Sat May 15 11:42:20 EDT 2010


Author: gjanssens
Date: 2010-05-15 11:42:20 -0400 (Sat, 15 May 2010)
New Revision: 19175
Trac: http://svn.gnucash.org/trac/changeset/19175

Added:
   htdocs/trunk/externals/gettext.inc
   htdocs/trunk/externals/gettext.php
   htdocs/trunk/externals/streams.php
   htdocs/trunk/locale/
   htdocs/trunk/locale/de/
   htdocs/trunk/locale/de/LC_MESSAGES/
   htdocs/trunk/locale/en_GB/
   htdocs/trunk/locale/en_GB/LC_MESSAGES/
   htdocs/trunk/locale/es/
   htdocs/trunk/locale/es/LC_MESSAGES/
   htdocs/trunk/locale/fr/
   htdocs/trunk/locale/fr/LC_MESSAGES/
   htdocs/trunk/locale/it/
   htdocs/trunk/locale/it/LC_MESSAGES/
   htdocs/trunk/locale/ja/
   htdocs/trunk/locale/ja/LC_MESSAGES/
   htdocs/trunk/locale/nb/
   htdocs/trunk/locale/nb/LC_MESSAGES/
   htdocs/trunk/locale/nl/
   htdocs/trunk/locale/nl/LC_MESSAGES/
   htdocs/trunk/locale/pl/
   htdocs/trunk/locale/pl/LC_MESSAGES/
   htdocs/trunk/locale/pt_PT/
   htdocs/trunk/locale/pt_PT/LC_MESSAGES/
   htdocs/trunk/locale/zh_CN/
   htdocs/trunk/locale/zh_CN/LC_MESSAGES/
Removed:
   htdocs/trunk/de/
   htdocs/trunk/en/
   htdocs/trunk/en_GB/
   htdocs/trunk/es/
   htdocs/trunk/fr/
   htdocs/trunk/it/
   htdocs/trunk/ja/
   htdocs/trunk/local.php
   htdocs/trunk/nb/
   htdocs/trunk/nl/
   htdocs/trunk/pl/
   htdocs/trunk/pt_PT/
   htdocs/trunk/zh_CN/
Modified:
   htdocs/trunk/Makefile
   htdocs/trunk/atom.php
   htdocs/trunk/docs.phtml
   htdocs/trunk/download.phtml
   htdocs/trunk/externals/footer.phtml
   htdocs/trunk/externals/header.phtml
   htdocs/trunk/externals/menu.phtml
   htdocs/trunk/features.phtml
   htdocs/trunk/index.phtml
   htdocs/trunk/lang.php
   htdocs/trunk/oldnews.phtml
   htdocs/trunk/search/templates/NMZ.body.php_tmpl
   htdocs/trunk/search/templates/NMZ.foot.php_tmpl
   htdocs/trunk/search/templates/NMZ.head.php_tmpl
   htdocs/trunk/search/templates/NMZ.result.normal.php_tmpl
   htdocs/trunk/search/templates/NMZ.result.short.php_tmpl
   htdocs/trunk/search/templates/NMZ.tips.php_tmpl
   htdocs/trunk/sizing.phtml
Log:
Use http GET variable and cookie to handle language selection
Patch by Tao Wang, with some additional tweaks for search

Modified: htdocs/trunk/Makefile
===================================================================
--- htdocs/trunk/Makefile	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/Makefile	2010-05-15 15:42:20 UTC (rev 19175)
@@ -21,7 +21,7 @@
 	  msgmerge -U po/$$f.po po/gnucash-htdocs.pot ; \
 	done
 
-mos: ${all_languages} 
+mos: ${all_languages}
 
 ${all_languages}: po/$$@.po
 	msgfmt $< -o $@/LC_MESSAGES/gnucash-htdocs.mo
@@ -40,15 +40,12 @@
 # add when we have utf-8 translations: iconv -f UTF-8 -t ISO8859-1 
 
 nmz.onefile:
-	( echo '<?php include("$(LOCALFILE)"); ' ; \
-	  echo '$$home = "$(HOME)/$$lang_dir"; ' ; \
-	  echo '$$text_dir = "."; ?>'; \
+	( echo '$$text_dir = "."; ?>'; \
 	  cat $(TMPLBASE)$(FILE).php_tmpl ) | php -q > \
 	  $(TMPLBASE)$(FILE)$(FILETAIL)
 
 nmz.lang:
-	$(MAKE) nmz.onefile FILE=head
-	for f in body foot result.normal result.short tips ; do \
+	for f in head body foot result.normal result.short tips ; do \
 	  $(MAKE) nmz.onefile FILE="$$f"; \
 	done
 
@@ -57,5 +54,5 @@
 	# other NMZ langs not merged into po system: ja
 	# note: PL is only "mostly" translated.  it diff's differently
 	for l in en ${languages} ; do \
-	  $(MAKE) nmz.lang LOCALFILE=$$l/local.php FILETAIL=.$$l ; \
+	  $(MAKE) nmz.lang FILETAIL=.$$l ; \
 	done

Modified: htdocs/trunk/atom.php
===================================================================
--- htdocs/trunk/atom.php	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/atom.php	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,7 +1,7 @@
 <?php
   // TODO:
   // - reasonable permalinks
-  include("local.php");
+#  include("local.php");
 
   $contentType = "application/atom+xml";
   $overrideContentType = $_GET["content-type"];

Modified: htdocs/trunk/docs.phtml
===================================================================
--- htdocs/trunk/docs.phtml	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/docs.phtml	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,118 +1,117 @@
 <?php 
-$title = _("Documentation Project");
-include("local.php");
 include("lang.php");
+$title = T_("Documentation Project");
 include("emulate_globals_on.php");
 include("externals/header.phtml");
 include("externals/menu.phtml");
 ?>
 <div id="content">
 
-<h1><?php echo _("GnuCash Documentation Project");?></h1>
+<h1><?php echo T_("GnuCash Documentation Project");?></h1>
 
-<p><?php echo _("This page is the home of the Gnucash Documentation Project, our goal is to maintain a community of people working towards creation of high quality documentation for GnuCash.");?></p>
+<p><?php echo T_("This page is the home of the Gnucash Documentation Project, our goal is to maintain a community of people working towards creation of high quality documentation for GnuCash.");?></p>
 
-<p><?php echo _("Everything you need concerning GnuCash documentation should be here, if you notice something missing, email <a href='mailto:gnucash-devel at lists.gnucash.org'>gnucash-devel</a> and we will add it.");?></p>
+<p><?php echo T_("Everything you need concerning GnuCash documentation should be here, if you notice something missing, email <a href='mailto:gnucash-devel at lists.gnucash.org'>gnucash-devel</a> and we will add it.");?></p>
 
-<h2><?= _("Nightly Documentation Builds");?></h2>
-<h3><?= _("current unstable user documentation and developer documentation");?></h3>
+<h2><?= T_("Nightly Documentation Builds");?></h2>
+<h3><?= T_("current unstable user documentation and developer documentation");?></h3>
 
-<p><?php echo _("Every night a server builds the documentation from the current contents of the GnuCash subversion repository.  This includes the Developer Documentation from Doxygen and User Documentation for the current unstable version of GnuCash.");?>
+<p><?php echo T_("Every night a server builds the documentation from the current contents of the GnuCash subversion repository.  This includes the Developer Documentation from Doxygen and User Documentation for the current unstable version of GnuCash.");?>
 
 <ul>
-  <li><?php echo _("Nightly Documentation Builds");?>:
+  <li><?php echo T_("Nightly Documentation Builds");?>:
     <ul>
-    <li><a href="http://svn.gnucash.org/docs/guide/"><?= _("Concepts Guide") ?></a></li>
-    <li><a href="http://svn.gnucash.org/docs/help/help.html"><?= _("Help Manual") ?></a></li>
-    <li><a href="http://svn.gnucash.org/docs/HEAD/"><?= _("Doxygen Developer Documentation") ?></a></li>
+    <li><a href="http://svn.gnucash.org/docs/guide/"><?= T_("Concepts Guide") ?></a></li>
+    <li><a href="http://svn.gnucash.org/docs/help/help.html"><?= T_("Help Manual") ?></a></li>
+    <li><a href="http://svn.gnucash.org/docs/HEAD/"><?= T_("Doxygen Developer Documentation") ?></a></li>
     </ul>
   </li>
 </ul>
 
-<h2><?=_("GnuCash v2.0 (current stable release)");?></h2>
+<h2><?=T_("GnuCash v2.0 (current stable release)");?></h2>
 
-<p><?php echo _("If you have a question about how to use GnuCash, you are in the right place. The first thing you should do is read the Help Manual and the Concepts Guide, most of your questions can probably be answered by these documents.");?></p>
-<p><?php echo _("The Help Manual is designed to be a quick reference of how to accomplish specific tasks and how to use the features in GnuCash. The Concepts Guide is designed to be an in depth guide to the concepts behind using GnuCash with a tutorial to show how to put those concepts into practice.");?></p>
+<p><?php echo T_("If you have a question about how to use GnuCash, you are in the right place. The first thing you should do is read the Help Manual and the Concepts Guide, most of your questions can probably be answered by these documents.");?></p>
+<p><?php echo T_("The Help Manual is designed to be a quick reference of how to accomplish specific tasks and how to use the features in GnuCash. The Concepts Guide is designed to be an in depth guide to the concepts behind using GnuCash with a tutorial to show how to put those concepts into practice.");?></p>
 
 
 <ul>
-  <li><?php echo _("Help Manual");?>
+  <li><?php echo T_("Help Manual");?>
     <ul>
-    <li><a href="<?=$top_dir;?>/docs/v2.0/C/gnucash-help/help.html"><?php echo _("English");?> (HTML)</a></li>
-    <li><a href="<?=$top_dir;?>/docs/v2.0/de_DE/gnucash-help/help.html"><?php echo _("Deutsch");?> (HTML)</a></li>
-    <!-- <li><a href="<?=$top_dir;?>/docs/v2.0/C/gnucash-help.pdf"><?php echo _("English");?> (PDF)</a></li> -->
+    <li><a href="<?=$top_dir;?>/docs/v2.0/C/gnucash-help/help.html"><?php echo T_("English");?> (HTML)</a></li>
+    <li><a href="<?=$top_dir;?>/docs/v2.0/de_DE/gnucash-help/help.html"><?php echo T_("Deutsch");?> (HTML)</a></li>
+    <!-- <li><a href="<?=$top_dir;?>/docs/v2.0/C/gnucash-help.pdf"><?php echo T_("English");?> (PDF)</a></li> -->
     </ul>
     </li>
   </li>
-  <li><?= _("Concepts Guide") ?>
+  <li><?= T_("Concepts Guide") ?>
     <ul>
-      <li><a href="<?=$top_dir;?>/docs/v2.0/C/gnucash-guide/"><?php echo _("English");?> (HTML)</a></li>
-      <!-- <li><a href="<?=$top_dir;?>/docs/v2.0/C/gnucash-guide.pdf"><?php echo _("English");?> (PDF)</a></li> -->
+      <li><a href="<?=$top_dir;?>/docs/v2.0/C/gnucash-guide/"><?php echo T_("English");?> (HTML)</a></li>
+      <!-- <li><a href="<?=$top_dir;?>/docs/v2.0/C/gnucash-guide.pdf"><?php echo T_("English");?> (PDF)</a></li> -->
     </ul>
   </li>
 </ul>
 
-<p><?php echo _("Please send an email to the <a href='mailto:gnucash-user at lists.gnucash.org'>gnucash-user</a> mailing list if you cannot find a satisfactory answer to your question within either the Help Manual or the Concepts Guide. We <b>want</b> feedback from you, it is only through your comments that we know how to modify the documentation.");?></p>
-<p><?php echo _("Additionally, you can talk to someone via IRC at irc.gnome.org channel \"#gnucash\" about your question.  Another resource is the <a href='http://wiki.gnucash.org/wiki/'>English</a> or <a href='http://linuxwiki.de/GnuCash'>Deutsch</a> GnuCash wikis. A wiki is an interactive website where registered users can ask and answer questions.");?></p>
+<p><?php echo T_("Please send an email to the <a href='mailto:gnucash-user at lists.gnucash.org'>gnucash-user</a> mailing list if you cannot find a satisfactory answer to your question within either the Help Manual or the Concepts Guide. We <b>want</b> feedback from you, it is only through your comments that we know how to modify the documentation.");?></p>
+<p><?php echo T_("Additionally, you can talk to someone via IRC at irc.gnome.org channel \"#gnucash\" about your question.  Another resource is the <a href='http://wiki.gnucash.org/wiki/'>English</a> or <a href='http://linuxwiki.de/GnuCash'>Deutsch</a> GnuCash wikis. A wiki is an interactive website where registered users can ask and answer questions.");?></p>
 
-<p><?php echo _("Some people have written HOWTO guides or tutorials. Note: the information presented in these sources may or may not be updated to the most recent version of GnuCash. If you are interested in doing development work on these documents, you should contact the original authors.");?></p>
+<p><?php echo T_("Some people have written HOWTO guides or tutorials. Note: the information presented in these sources may or may not be updated to the most recent version of GnuCash. If you are interested in doing development work on these documents, you should contact the original authors.");?></p>
 <ul>
-  <li><a href="http://code.neil.williamsleesmill.me.uk/otherdocs.html"><?php echo _("Neil Williams GnuCash documentation");?></a></li>
-  <li><a href="http://www.aerospacesoftware.com/GNU_Cash_for_Business_users_Howto_Guide.html"><?php echo _("GnuCash for Business Users");?></a>
-    (<a href="http://www.linas.org/mirrors/www.aerospacesoftware.com/2003.06.21/GNU_Cash_for_Business_users_Howto_Guide.html"><?php echo _("mirror");?></a>)</li>
+  <li><a href="http://code.neil.williamsleesmill.me.uk/otherdocs.html"><?php echo T_("Neil Williams GnuCash documentation");?></a></li>
+  <li><a href="http://www.aerospacesoftware.com/GNU_Cash_for_Business_users_Howto_Guide.html"><?php echo T_("GnuCash for Business Users");?></a>
+    (<a href="http://www.linas.org/mirrors/www.aerospacesoftware.com/2003.06.21/GNU_Cash_for_Business_users_Howto_Guide.html"><?php echo T_("mirror");?></a>)</li>
   <li><a href="http://www.austintek.com/gnucash/ncsa-gnucash-talk.html"><?php
-	echo _("Joe Mack's Tutorial");?></a></li>
+	echo T_("Joe Mack's Tutorial");?></a></li>
   <li><a href="http://www.object-refinery.com/gnucash/index.html"><?php
-	echo _("Dave Gilbert's User Guide (PDF)");?></a></li>
+	echo T_("Dave Gilbert's User Guide (PDF)");?></a></li>
 </ul>
 
-<h2><?php echo _("Older GnuCash Documentation");?></h2>
-<p><?php echo _("This section contains all the older GnuCash documentation. If you are using one of these old versions of GnuCash, it is highly recommended that you upgrade to the latest stable version.");?></p>
+<h2><?php echo T_("Older GnuCash Documentation");?></h2>
+<p><?php echo T_("This section contains all the older GnuCash documentation. If you are using one of these old versions of GnuCash, it is highly recommended that you upgrade to the latest stable version.");?></p>
 <ul>
   <li><b>GnuCash v1.8</b>:
-    <ul><b><?php echo _("Help Manual");?></b>:
-      <a href="<?=$top_dir;?>/docs/v1.8/C/gnucash-help/help.html"><?php echo _("English");?> (HTML)</a>
-      <a href="<?=$top_dir;?>/docs/v1.8/de_DE/gnucash-help/help.html"><?php echo _("Deutsch");?> (HTML)</a>
-      <a href="<?=$top_dir;?>/docs/v1.8/C/gnucash-help.pdf"><?php echo _("English");?> (PDF)</a>
+    <ul><b><?php echo T_("Help Manual");?></b>:
+      <a href="<?=$top_dir;?>/docs/v1.8/C/gnucash-help/help.html"><?php echo T_("English");?> (HTML)</a>
+      <a href="<?=$top_dir;?>/docs/v1.8/de_DE/gnucash-help/help.html"><?php echo T_("Deutsch");?> (HTML)</a>
+      <a href="<?=$top_dir;?>/docs/v1.8/C/gnucash-help.pdf"><?php echo T_("English");?> (PDF)</a>
     </ul>
-    <ul><b><?= _("Concepts Guide") ?></b>:
-      <a href="<?=$top_dir;?>/docs/v1.8/C/gnucash-guide/"><?php echo _("English");?> (HTML)</a>
-      <a href="<?=$top_dir;?>/docs/v1.8/C/gnucash-guide.pdf"><?php echo _("English");?> (PDF)</a>
+    <ul><b><?= T_("Concepts Guide") ?></b>:
+      <a href="<?=$top_dir;?>/docs/v1.8/C/gnucash-guide/"><?php echo T_("English");?> (HTML)</a>
+      <a href="<?=$top_dir;?>/docs/v1.8/C/gnucash-guide.pdf"><?php echo T_("English");?> (PDF)</a>
     </ul>
   </li>
   <li><b>GnuCash v1.6</b>: 
-  <a href="<?=$top_dir;?>/docs/v1.6/C/"><?php echo _("English");?></a> | 
-  <a href="<?=$top_dir;?>/docs/v1.6/de_DE/"><?php echo _("Deutsch");?></a> | 
-  <a href="<?=$top_dir;?>/docs/v1.6/es/"><?php echo _("Espagnol");?></a> | 
-  <a href="<?=$top_dir;?>/docs/v1.6/pt_PT/"><?php echo _("Portugu&ecirc;s");?></a></li>
+  <a href="<?=$top_dir;?>/docs/v1.6/C/"><?php echo T_("English");?></a> | 
+  <a href="<?=$top_dir;?>/docs/v1.6/de_DE/"><?php echo T_("Deutsch");?></a> | 
+  <a href="<?=$top_dir;?>/docs/v1.6/es/"><?php echo T_("Espagnol");?></a> | 
+  <a href="<?=$top_dir;?>/docs/v1.6/pt_PT/"><?php echo T_("Portugu&ecirc;s");?></a></li>
 </ul>
 
-<h2><?php echo _("Documentation Development");?></h2>
+<h2><?php echo T_("Documentation Development");?></h2>
 
-<h3><?php echo _("Interesting Links");?></h3>
-<?php echo _("The following links are for further sites that can help with the documentation and review process.");?>
+<h3><?php echo T_("Interesting Links");?></h3>
+<?php echo T_("The following links are for further sites that can help with the documentation and review process.");?>
 <ul>
 <li><a href='http://www.docbook.org'> DocBook: The Definitive Guide.</a></li>
 <li><a href='http://www.sagehill.net/docbookxsl/'>DocBook XSL: The Complete Guide</a>.</li>
 <li><a href='http://developer.gnome.org/projects/gup/hig/2.0/'> GNOME Human Interface Guidelines</a></li>
 </ul>
 
-<h3><?php echo _("For both reviewers and documentation writers");?></h3>
-<?php echo _("Please read the following guides. The new docs are based on the GNOME2 XML docbook system. Everyone wishing to help please follow these guides where possible when reviewing and/or writing docs.");?></p>
+<h3><?php echo T_("For both reviewers and documentation writers");?></h3>
+<?php echo T_("Please read the following guides. The new docs are based on the GNOME2 XML docbook system. Everyone wishing to help please follow these guides where possible when reviewing and/or writing docs.");?></p>
 <ul>
 <li><a href='http://developer.gnome.org/projects/gdp/styleguide.html'>The GNOME Documentation Style Guide</a></li>
 <li><a href='http://developer.gnome.org/projects/gdp/handbook.html'>The GNOME Handbook of Writing Software Documentation</a></li>
 </ul>
-<p><?php echo _("We suggest also subscribing to ");?><a href='mailto:gnucash-devel at lists.gnucash.org'>gnucash-devel</a>.</p>
+<p><?php echo T_("We suggest also subscribing to ");?><a href='mailto:gnucash-devel at lists.gnucash.org'>gnucash-devel</a>.</p>
 
-<h3><?php echo _("Reviewers");?></h3>
-<p><?php echo _("Please check out the documentation module from the GnuCash svn - gnucash-docs. For those not familiar with svn, the GnuCash wiki has a <a href='http://wiki.gnucash.org/wiki/Subversion'>description.</a> The only change to get the docs is to change the checkout gnucash to checkout gnucash-docs. You can also start from the current docs tarball.");?></p>
-<p><?php echo _("The best way of retaining comments about docs in an easy to find way for everyone would be to use <a href='http://bugzilla.gnome.org/'>bugzilla.gnome.org</a> to file the bugs under documentation. This can also be done using bug-buddy.");?></p>
+<h3><?php echo T_("Reviewers");?></h3>
+<p><?php echo T_("Please check out the documentation module from the GnuCash svn - gnucash-docs. For those not familiar with svn, the GnuCash wiki has a <a href='http://wiki.gnucash.org/wiki/Subversion'>description.</a> The only change to get the docs is to change the checkout gnucash to checkout gnucash-docs. You can also start from the current docs tarball.");?></p>
+<p><?php echo T_("The best way of retaining comments about docs in an easy to find way for everyone would be to use <a href='http://bugzilla.gnome.org/'>bugzilla.gnome.org</a> to file the bugs under documentation. This can also be done using bug-buddy.");?></p>
 
-<h3><?php echo _("Writers");?></h3>
-<p><?php echo _("Also checkout the docs svn as above. The usual procedure for contributors to GnuCash is to initially submit patches to the <a href='mailto:gnucash-devel at lists.gnucash.org'>gnucash-devel</a> mailing list. We will handle getting the patches added into svn until you are given an account. You can also add the patch to a bug report in bugzilla if you wish.");?></p>
-<p><?php echo _("Please let other writers know which section you wish to tackle. Please forward this to <a href='mailto:gnucash-devel at lists.gnucash.org'>gnucash-devel</a> so that people can say 'hey I'm doing that already' or 'go ahead and do it'.");?></p>
-<p><?php echo _("You may also want to retain a local copy of the old documentation to refer to when writing. This still has a lot of useful information in it which hasn't been transferred to the new docs");?></p>
+<h3><?php echo T_("Writers");?></h3>
+<p><?php echo T_("Also checkout the docs svn as above. The usual procedure for contributors to GnuCash is to initially submit patches to the <a href='mailto:gnucash-devel at lists.gnucash.org'>gnucash-devel</a> mailing list. We will handle getting the patches added into svn until you are given an account. You can also add the patch to a bug report in bugzilla if you wish.");?></p>
+<p><?php echo T_("Please let other writers know which section you wish to tackle. Please forward this to <a href='mailto:gnucash-devel at lists.gnucash.org'>gnucash-devel</a> so that people can say 'hey I'm doing that already' or 'go ahead and do it'.");?></p>
+<p><?php echo T_("You may also want to retain a local copy of the old documentation to refer to when writing. This still has a lot of useful information in it which hasn't been transferred to the new docs");?></p>
     
 </div>
 <?php include("externals/footer.phtml"); ?>

Modified: htdocs/trunk/download.phtml
===================================================================
--- htdocs/trunk/download.phtml	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/download.phtml	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,61 +1,60 @@
 <?php 
 $homepage = false;
-$title = _("Download");
-include("local.php");
 include("emulate_globals_on.php");
 include("lang.php");
+$title = T_("Download");
 include("externals/header.phtml");
 include("externals/menu.phtml"); 
 ?>
 
 <div id="content">
 
-<h1><?php echo _("Download GnuCash")?></h1>
+<h1><?php echo T_("Download GnuCash")?></h1>
 
-<h2><?php printf (_("Stable release (%s)"), $latest_stable)?></h2>
-<p><?php echo _("A stable release is a version of GnuCash that is well tested and considered appropriate for every day use.")?></p>
-<p><?php printf (_("The latest stable release of GnuCash is %s.  Choose the download for your operating system below."), $latest_stable)?></p>
+<h2><?php printf (T_("Stable release (%s)"), $latest_stable)?></h2>
+<p><?php echo T_("A stable release is a version of GnuCash that is well tested and considered appropriate for every day use.")?></p>
+<p><?php printf (T_("The latest stable release of GnuCash is %s.  Choose the download for your operating system below."), $latest_stable)?></p>
 
-<h3><?php echo _("Installers")?></h3>
+<h3><?php echo T_("Installers")?></h3>
 <ul>
-<li><?php printf (_("GnuCash %s for"), $latest_stable)?> <a href="<?php echo $download_path.$latest_stable_win;?>">Microsoft Windows XP/Vista/7</a></li>
-<li><?php printf (_("GnuCash %s for"), $latest_stable)?> Mac OS X <a href="<?php echo $download_path.$latest_stable_mac_intel;?>">Intel</a> | <a href="<?php echo $download_path.$latest_stable_mac_ppc;?>">Power PC</a> | <a href="http://wiki.gnucash.org/wiki/MacOSX/<?php echo $latest_stable;?>/Readme">Readme</a></li>
+<li><?php printf (T_("GnuCash %s for"), $latest_stable)?> <a href="<?php echo $download_path.$latest_stable_win;?>">Microsoft Windows XP/Vista/7</a></li>
+<li><?php printf (T_("GnuCash %s for"), $latest_stable)?> Mac OS X <a href="<?php echo $download_path.$latest_stable_mac_intel;?>">Intel</a> | <a href="<?php echo $download_path.$latest_stable_mac_ppc;?>">Power PC</a> | <a href="http://wiki.gnucash.org/wiki/MacOSX/<?php echo $latest_stable;?>/Readme">Readme</a></li>
 </ul>
 
 <a name="distribution"></a><h3>Linux</h3>
-<p><?php echo _("Most linux distributions come bundled with a version of GnuCash, though it's not always the most recent version and it may not have been installed by default. Still it is recommended to use the GnuCash version that comes with your distribution.");?></p>
-<p><?php echo _("Below are ways to install GnuCash on some of the more popular distributions:");?></p>
+<p><?php echo T_("Most linux distributions come bundled with a version of GnuCash, though it's not always the most recent version and it may not have been installed by default. Still it is recommended to use the GnuCash version that comes with your distribution.");?></p>
+<p><?php echo T_("Below are ways to install GnuCash on some of the more popular distributions:");?></p>
 
 <ul>
-  <li><b>Fedora: </b><?php echo _("Fedora users can install GnuCash through System->Administration->Add/Remove Software (Gnome) or Applications->System->Software Management (KDE).")?></li>
-  <li><b>Mandriva: </b><?php echo _("Mandriva users can install GnuCash through the Software Management in the Mandriva Linux Control Center.")?></li>
-  <li><b>Redhat/Centos: </b><?php echo _("Redhat and CentOS don't have GnuCash in their repositories by default. It can be installed however from the third-party Epel repository. For more details on configuring this additional software repository for your setup, see ");?><a href="http://fedoraproject.org/wiki/EPEL"><?php echo _("Epel's wiki page");?></a></li>
-  <li><b>Ubuntu: </b><?php echo _("Ubuntu 9.10 users can install GnuCash through the Software Center (in the Applications menu). This will install GnuCash under the Office category in the Applications menu.")?></li>
+  <li><b>Fedora: </b><?php echo T_("Fedora users can install GnuCash through System->Administration->Add/Remove Software (Gnome) or Applications->System->Software Management (KDE).")?></li>
+  <li><b>Mandriva: </b><?php echo T_("Mandriva users can install GnuCash through the Software Management in the Mandriva Linux Control Center.")?></li>
+  <li><b>Redhat/Centos: </b><?php echo T_("Redhat and CentOS don't have GnuCash in their repositories by default. It can be installed however from the third-party Epel repository. For more details on configuring this additional software repository for your setup, see ");?><a href="http://fedoraproject.org/wiki/EPEL"><?php echo T_("Epel's wiki page");?></a></li>
+  <li><b>Ubuntu: </b><?php echo T_("Ubuntu 9.10 users can install GnuCash through the Software Center (in the Applications menu). This will install GnuCash under the Office category in the Applications menu.")?></li>
 </ul>
 
-<h3><?php echo _("Source code")?></h3>
+<h3><?php echo T_("Source code")?></h3>
 <ul>
-  <li><a href="<?php echo $download_path.$latest_stable_source;?>">bzip2 compressed tarball</a> <?php printf (_("for GnuCash %s"), $latest_stable)?></li>
-  <li><a href="http://www.gnucash.org/pub/gnucash/sources/stable/<?php echo $latest_stable_source;?>"><?= _("USA Mirror");?></a></li>
-  <li><a href="http://ftp.at.gnucash.org/pub/gnucash/sources/stable/<?php echo $latest_stable_source;?>"><?= _("European Mirror");?></a></li>
+  <li><a href="<?php echo $download_path.$latest_stable_source;?>">bzip2 compressed tarball</a> <?php printf (T_("for GnuCash %s"), $latest_stable)?></li>
+  <li><a href="http://www.gnucash.org/pub/gnucash/sources/stable/<?php echo $latest_stable_source;?>"><?= T_("USA Mirror");?></a></li>
+  <li><a href="http://ftp.at.gnucash.org/pub/gnucash/sources/stable/<?php echo $latest_stable_source;?>"><?= T_("European Mirror");?></a></li>
  </ul>
 
-<h2><?php printf (_("Unstable/Development release (%s)"), $latest_unstable)?></h2>
-<p><?php echo _("Unstable (development) releases are for testing purposes only. They contain the newest features and improvements, but may also contain serious bugs still. Don't install these releases for everyday use.")?></p>
-<p><?php printf (_("The latest unstable release of GnuCash is %s.  Choose the download for your operating system below."), $latest_unstable)?></p>
+<h2><?php printf (T_("Unstable/Development release (%s)"), $latest_unstable)?></h2>
+<p><?php echo T_("Unstable (development) releases are for testing purposes only. They contain the newest features and improvements, but may also contain serious bugs still. Don't install these releases for everyday use.")?></p>
+<p><?php printf (T_("The latest unstable release of GnuCash is %s.  Choose the download for your operating system below."), $latest_unstable)?></p>
 
 <ul>
-  <li><?php printf (_("GnuCash %s for"), $latest_unstable)?> <a href="<?php echo $download_path.$latest_unstable_win;?>">Microsoft Windows XP/Vista/7</a></li>
-  <li><?php printf (_("GnuCash %s for"), $latest_unstable)?> Mac OS X <a href="<?php echo $download_path.$latest_unstable_mac_intel;?>">Intel</a> | <a href="http://wiki.gnucash.org/wiki/MacOSX/<?php echo $latest_unstable;?>/Readme">Readme</a></li>
-  <li><a href="<?php echo $download_path.$latest_unstable_source;?>">bzip2 compressed tarball</a> <?php printf (_("for GnuCash %s"), $latest_unstable)?></li>
+  <li><?php printf (T_("GnuCash %s for"), $latest_unstable)?> <a href="<?php echo $download_path.$latest_unstable_win;?>">Microsoft Windows XP/Vista/7</a></li>
+  <li><?php printf (T_("GnuCash %s for"), $latest_unstable)?> Mac OS X <a href="<?php echo $download_path.$latest_unstable_mac_intel;?>">Intel</a> | <a href="http://wiki.gnucash.org/wiki/MacOSX/<?php echo $latest_unstable;?>/Readme">Readme</a></li>
+  <li><a href="<?php echo $download_path.$latest_unstable_source;?>">bzip2 compressed tarball</a> <?php printf (T_("for GnuCash %s"), $latest_unstable)?></li>
 </ul>
 
-<h2><?php echo _("Other")?></h2>
+<h2><?php echo T_("Other")?></h2>
 
 <ul>
- <li><a href="<?php echo $latest_stable_path;?>"><?php printf (_("View all GnuCash %s downloads (stable)"), $latest_stable)?></a></li>
- <li><a href="<?php echo $latest_unstable_path;?>"><?php printf (_("View all GnuCash %s downloads (unstable)"), $latest_unstable)?></a></li>
- <li><a href="http://sourceforge.net/projects/gnucash/files/"><?php echo _("View all GnuCash downloads")?></a></li>
+ <li><a href="<?php echo $latest_stable_path;?>"><?php printf (T_("View all GnuCash %s downloads (stable)"), $latest_stable)?></a></li>
+ <li><a href="<?php echo $latest_unstable_path;?>"><?php printf (T_("View all GnuCash %s downloads (unstable)"), $latest_unstable)?></a></li>
+ <li><a href="http://sourceforge.net/projects/gnucash/files/"><?php echo T_("View all GnuCash downloads")?></a></li>
 </ul>
 
 </div>

Modified: htdocs/trunk/externals/footer.phtml
===================================================================
--- htdocs/trunk/externals/footer.phtml	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/externals/footer.phtml	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,8 +1,8 @@
 <div id="tail">
 <p id="rss"><a href="<?=$home?>/atom.php"><img src="<?=$top_dir?>/externals/feed-icon-32x32.png" alt="[atom syndication feed]" width="32" height="32" /></a></p>
 <p>Copyright &copy; 2001-2009 The GnuCash Project</p>
-<p><?= _("Server &amp; email outage reports to: ")?><a href="mailto:gnucash-devel at gnucash.org">gnucash-devel at gnucash.org</a></p>
-<p><?= _("Translation problems? Contact: <a href=\"mailto:gnucash-devel at gnucash.org\"><b>gnucash-devel at gnucash.org</b></a>");?></p>
+<p><?= T_("Server &amp; email outage reports to: ")?><a href="mailto:gnucash-devel at gnucash.org">gnucash-devel at gnucash.org</a></p>
+<p><?= T_("Translation problems? Contact: <a href=\"mailto:gnucash-devel at gnucash.org\"><b>gnucash-devel at gnucash.org</b></a>");?></p>
 </div>
 </body>
 </html>

Added: htdocs/trunk/externals/gettext.inc
===================================================================
--- htdocs/trunk/externals/gettext.inc	                        (rev 0)
+++ htdocs/trunk/externals/gettext.inc	2010-05-15 15:42:20 UTC (rev 19175)
@@ -0,0 +1,374 @@
+<?php
+/*
+   Copyright (c) 2005 Steven Armstrong <sa at c-area dot ch>
+   Copyright (c) 2009 Danilo Segan <danilo at kvota.net>
+
+   Drop in replacement for native gettext.
+
+   This file is part of PHP-gettext.
+
+   PHP-gettext is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2 of the License, or
+   (at your option) any later version.
+
+   PHP-gettext is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU General Public License for more details.
+
+   You should have received a copy of the GNU General Public License
+   along with PHP-gettext; if not, write to the Free Software
+   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+
+*/
+/*
+LC_CTYPE        0
+LC_NUMERIC      1
+LC_TIME         2
+LC_COLLATE      3
+LC_MONETARY     4
+LC_MESSAGES     5
+LC_ALL          6
+*/
+
+
+// LC_MESSAGES is not available if php-gettext is not loaded
+// while the other constants are already available from session extension.
+if (!defined('LC_MESSAGES')) {
+  define('LC_MESSAGES',	5);
+}
+
+require('streams.php');
+require('gettext.php');
+
+
+// Variables
+
+global $text_domains, $default_domain, $LC_CATEGORIES, $EMULATEGETTEXT, $CURRENTLOCALE;
+$text_domains = array();
+$default_domain = 'messages';
+$LC_CATEGORIES = array('LC_CTYPE', 'LC_NUMERIC', 'LC_TIME', 'LC_COLLATE', 'LC_MONETARY', 'LC_MESSAGES', 'LC_ALL');
+$EMULATEGETTEXT = 0;
+$CURRENTLOCALE = '';
+
+/* Class to hold a single domain included in $text_domains. */
+class domain {
+  var $l10n;
+  var $path;
+  var $codeset;
+}
+
+// Utility functions
+
+/**
+ * Utility function to get a StreamReader for the given text domain.
+ */
+function _get_reader($domain=null, $category=5, $enable_cache=true) {
+    global $text_domains, $default_domain, $LC_CATEGORIES;
+    if (!isset($domain)) $domain = $default_domain;
+    if (!isset($text_domains[$domain]->l10n)) {
+        // get the current locale
+        $locale = _setlocale(LC_MESSAGES, 0);
+        $bound_path = isset($text_domains[$domain]->path) ?
+          $text_domains[$domain]->path : './';
+        $subpath = $LC_CATEGORIES[$category] ."/$domain.mo";
+        /* Figure out all possible locale names and start with the most
+           specific ones.  I.e. for sr_CS.UTF-8 at latin, look through all of
+           sr_CS.UTF-8 at latin, sr_CS at latin, sr at latin, sr_CS.UTF-8, sr_CS, sr.
+        */
+        $locale_names = array();
+        if (preg_match("/([a-z]{2,3})"            // language code
+                       ."(_([A-Z]{2}))?"          // country code
+                       ."(\.([-A-Za-z0-9_]))?"    // charset
+                       ."(@([-A-Za-z0-9_]+))?/",  // @ modifier
+                       $locale, $matches)) {
+          list(,$lang,,$country,,$charset,,$modifier) = $matches;
+          if ($modifier) {
+            $locale_names = array("${lang}_$country.$charset@$modifier",
+                                  "${lang}_$country@$modifier",
+                                  "$lang@$modifier");
+          }
+          array_push($locale_names,
+                     "${lang}_$country.$charset", "${lang}_$country", "$lang");
+        }
+        array_push($locale_names, $locale);
+
+        $input = null;
+        foreach ($locale_names as $locale) {
+          $full_path = $bound_path . $locale . "/" . $subpath;
+          if (file_exists($full_path)) {
+            $input = new FileReader($full_path);
+            break;
+          }
+        }
+
+        if (!array_key_exists($domain, $text_domains)) {
+          // Initialize an empty domain object.
+          $text_domains[$domain] = new domain();
+        }
+        $text_domains[$domain]->l10n = new gettext_reader($input,
+                                                          $enable_cache);
+    }
+    return $text_domains[$domain]->l10n;
+}
+
+/**
+ * Returns whether we are using our emulated gettext API or PHP built-in one.
+ */
+function locale_emulation() {
+    global $EMULATEGETTEXT;
+    return $EMULATEGETTEXT;
+}
+
+/**
+ * Checks if the current locale is supported on this system.
+ */
+function _check_locale() {
+    global $EMULATEGETTEXT;
+    return !$EMULATEGETTEXT;
+}
+
+/**
+ * Get the codeset for the given domain.
+ */
+function _get_codeset($domain=null) {
+    global $text_domains, $default_domain, $LC_CATEGORIES;
+    if (!isset($domain)) $domain = $default_domain;
+    return (isset($text_domains[$domain]->codeset))? $text_domains[$domain]->codeset : ini_get('mbstring.internal_encoding');
+}
+
+/**
+ * Convert the given string to the encoding set by bind_textdomain_codeset.
+ */
+function _encode($text) {
+    $source_encoding = mb_detect_encoding($text);
+    $target_encoding = _get_codeset();
+    if ($source_encoding != $target_encoding) {
+        return mb_convert_encoding($text, $target_encoding, $source_encoding);
+    }
+    else {
+        return $text;
+    }
+}
+
+
+
+
+// Custom implementation of the standard gettext related functions
+
+/**
+ * Sets a requested locale, if needed emulates it.
+ */
+function _setlocale($category, $locale) {
+    global $CURRENTLOCALE, $EMULATEGETTEXT;
+    if ($locale === 0) { // use === to differentiate between string "0"
+        if ($CURRENTLOCALE != '')
+            return $CURRENTLOCALE;
+        else
+            // obey LANG variable, maybe extend to support all of LC_* vars
+            // even if we tried to read locale without setting it first
+            return _setlocale($category, $CURRENTLOCALE);
+    } else {
+        $ret = 0;
+        if (function_exists('setlocale')) // I don't know if this ever happens ;)
+           $ret = setlocale($category, $locale);
+        if (($ret and $locale == '') or ($ret == $locale)) {
+            $EMULATEGETTEXT = 0;
+            $CURRENTLOCALE = $ret;
+        } else {
+          if ($locale == '') // emulate variable support
+             $CURRENTLOCALE = getenv('LANG');
+        else
+            $CURRENTLOCALE = $locale;
+            $EMULATEGETTEXT = 1;
+        }
+        // Allow locale to be changed on the go for one translation domain.
+        global $text_domains, $default_domain;
+        unset($text_domains[$default_domain]->l10n);
+        return $CURRENTLOCALE;
+    }
+}
+
+/**
+ * Sets the path for a domain.
+ */
+function _bindtextdomain($domain, $path) {
+    global $text_domains;
+    // ensure $path ends with a slash ('/' should work for both, but lets still play nice)
+    if (substr(php_uname(), 0, 7) == "Windows") {
+      if ($path[strlen($path)-1] != '\\' and $path[strlen($path)-1] != '/')
+        $path .= '\\';
+    } else {
+      if ($path[strlen($path)-1] != '/')
+        $path .= '/';
+    }
+    if (!array_key_exists($domain, $text_domains)) {
+      // Initialize an empty domain object.
+      $text_domains[$domain] = new domain();
+    }
+    $text_domains[$domain]->path = $path;
+}
+
+/**
+ * Specify the character encoding in which the messages from the DOMAIN message catalog will be returned.
+ */
+function _bind_textdomain_codeset($domain, $codeset) {
+    global $text_domains;
+    $text_domains[$domain]->codeset = $codeset;
+}
+
+/**
+ * Sets the default domain.
+ */
+function _textdomain($domain) {
+    global $default_domain;
+    $default_domain = $domain;
+}
+
+/**
+ * Lookup a message in the current domain.
+ */
+function _gettext($msgid) {
+    $l10n = _get_reader();
+    //return $l10n->translate($msgid);
+    return _encode($l10n->translate($msgid));
+}
+/**
+ * Alias for gettext.
+ */
+function __($msgid) {
+    return _gettext($msgid);
+}
+/**
+ * Plural version of gettext.
+ */
+function _ngettext($single, $plural, $number) {
+    $l10n = _get_reader();
+    //return $l10n->ngettext($single, $plural, $number);
+    return _encode($l10n->ngettext($single, $plural, $number));
+}
+
+/**
+ * Override the current domain.
+ */
+function _dgettext($domain, $msgid) {
+    $l10n = _get_reader($domain);
+    //return $l10n->translate($msgid);
+    return _encode($l10n->translate($msgid));
+}
+/**
+ * Plural version of dgettext.
+ */
+function _dngettext($domain, $single, $plural, $number) {
+    $l10n = _get_reader($domain);
+    //return $l10n->ngettext($single, $plural, $number);
+    return _encode($l10n->ngettext($single, $plural, $number));
+}
+
+/**
+ * Overrides the domain and category for a single lookup.
+ */
+function _dcgettext($domain, $msgid, $category) {
+    $l10n = _get_reader($domain, $category);
+    //return $l10n->translate($msgid);
+    return _encode($l10n->translate($msgid));
+}
+/**
+ * Plural version of dcgettext.
+ */
+function _dcngettext($domain, $single, $plural, $number, $category) {
+    $l10n = _get_reader($domain, $category);
+    //return $l10n->ngettext($single, $plural, $number);
+    return _encode($l10n->ngettext($single, $plural, $number));
+}
+
+
+
+// Wrappers to use if the standard gettext functions are available, but the current locale is not supported by the system.
+// Use the standard impl if the current locale is supported, use the custom impl otherwise.
+
+function T_setlocale($category, $locale) {
+    return _setlocale($category, $locale);
+}
+
+function T_bindtextdomain($domain, $path) {
+    if (_check_locale()) return bindtextdomain($domain, $path);
+    else return _bindtextdomain($domain, $path);
+}
+function T_bind_textdomain_codeset($domain, $codeset) {
+    // bind_textdomain_codeset is available only in PHP 4.2.0+
+    if (_check_locale() and function_exists('bind_textdomain_codeset')) return bind_textdomain_codeset($domain, $codeset);
+    else return _bind_textdomain_codeset($domain, $codeset);
+}
+function T_textdomain($domain) {
+    if (_check_locale()) return textdomain($domain);
+    else return _textdomain($domain);
+}
+function T_gettext($msgid) {
+    if (_check_locale()) return gettext($msgid);
+    else return _gettext($msgid);
+}
+function T_($msgid) {
+    if (_check_locale()) return _($msgid);
+    return __($msgid);
+}
+function T_ngettext($single, $plural, $number) {
+    if (_check_locale()) return ngettext($single, $plural, $number);
+    else return _ngettext($single, $plural, $number);
+}
+function T_dgettext($domain, $msgid) {
+    if (_check_locale()) return dgettext($domain, $msgid);
+    else return _dgettext($domain, $msgid);
+}
+function T_dngettext($domain, $single, $plural, $number) {
+    if (_check_locale()) return dngettext($domain, $single, $plural, $number);
+    else return _dngettext($domain, $single, $plural, $number);
+}
+function T_dcgettext($domain, $msgid, $category) {
+    if (_check_locale()) return dcgettext($domain, $msgid, $category);
+    else return _dcgettext($domain, $msgid, $category);
+}
+function T_dcngettext($domain, $single, $plural, $number, $category) {
+    if (_check_locale()) return dcngettext($domain, $single, $plural, $number, $category);
+    else return _dcngettext($domain, $single, $plural, $number, $category);
+}
+
+
+
+// Wrappers used as a drop in replacement for the standard gettext functions
+
+if (!function_exists('gettext')) {
+    function bindtextdomain($domain, $path) {
+        return _bindtextdomain($domain, $path);
+    }
+    function bind_textdomain_codeset($domain, $codeset) {
+        return _bind_textdomain_codeset($domain, $codeset);
+    }
+    function textdomain($domain) {
+        return _textdomain($domain);
+    }
+    function gettext($msgid) {
+        return _gettext($msgid);
+    }
+    function _($msgid) {
+        return __($msgid);
+    }
+    function ngettext($single, $plural, $number) {
+        return _ngettext($single, $plural, $number);
+    }
+    function dgettext($domain, $msgid) {
+        return _dgettext($domain, $msgid);
+    }
+    function dngettext($domain, $single, $plural, $number) {
+        return _dngettext($domain, $single, $plural, $number);
+    }
+    function dcgettext($domain, $msgid, $category) {
+        return _dcgettext($domain, $msgid, $category);
+    }
+    function dcngettext($domain, $single, $plural, $number, $category) {
+        return _dcngettext($domain, $single, $plural, $number, $category);
+    }
+}
+
+?>

Added: htdocs/trunk/externals/gettext.php
===================================================================
--- htdocs/trunk/externals/gettext.php	                        (rev 0)
+++ htdocs/trunk/externals/gettext.php	2010-05-15 15:42:20 UTC (rev 19175)
@@ -0,0 +1,398 @@
+<?php
+/*
+   Copyright (c) 2003, 2009 Danilo Segan <danilo at kvota.net>.
+   Copyright (c) 2005 Nico Kaiser <nico at siriux.net>
+
+   This file is part of PHP-gettext.
+
+   PHP-gettext is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2 of the License, or
+   (at your option) any later version.
+
+   PHP-gettext is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU General Public License for more details.
+
+   You should have received a copy of the GNU General Public License
+   along with PHP-gettext; if not, write to the Free Software
+   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+
+*/
+
+/**
+ * Provides a simple gettext replacement that works independently from
+ * the system's gettext abilities.
+ * It can read MO files and use them for translating strings.
+ * The files are passed to gettext_reader as a Stream (see streams.php)
+ *
+ * This version has the ability to cache all strings and translations to
+ * speed up the string lookup.
+ * While the cache is enabled by default, it can be switched off with the
+ * second parameter in the constructor (e.g. whenusing very large MO files
+ * that you don't want to keep in memory)
+ */
+class gettext_reader {
+  //public:
+   var $error = 0; // public variable that holds error code (0 if no error)
+
+   //private:
+  var $BYTEORDER = 0;        // 0: low endian, 1: big endian
+  var $STREAM = NULL;
+  var $short_circuit = false;
+  var $enable_cache = false;
+  var $originals = NULL;      // offset of original table
+  var $translations = NULL;    // offset of translation table
+  var $pluralheader = NULL;    // cache header field for plural forms
+  var $total = 0;          // total string count
+  var $table_originals = NULL;  // table for original strings (offsets)
+  var $table_translations = NULL;  // table for translated strings (offsets)
+  var $cache_translations = NULL;  // original -> translation mapping
+
+
+  /* Methods */
+
+
+  /**
+   * Reads a 32bit Integer from the Stream
+   *
+   * @access private
+   * @return Integer from the Stream
+   */
+  function readint() {
+      if ($this->BYTEORDER == 0) {
+        // low endian
+        $input=unpack('V', $this->STREAM->read(4));
+        return array_shift($input);
+      } else {
+        // big endian
+        $input=unpack('N', $this->STREAM->read(4));
+        return array_shift($input);
+      }
+    }
+
+  function read($bytes) {
+    return $this->STREAM->read($bytes);
+  }
+
+  /**
+   * Reads an array of Integers from the Stream
+   *
+   * @param int count How many elements should be read
+   * @return Array of Integers
+   */
+  function readintarray($count) {
+    if ($this->BYTEORDER == 0) {
+        // low endian
+        return unpack('V'.$count, $this->STREAM->read(4 * $count));
+      } else {
+        // big endian
+        return unpack('N'.$count, $this->STREAM->read(4 * $count));
+      }
+  }
+
+  /**
+   * Constructor
+   *
+   * @param object Reader the StreamReader object
+   * @param boolean enable_cache Enable or disable caching of strings (default on)
+   */
+  function gettext_reader($Reader, $enable_cache = true) {
+    // If there isn't a StreamReader, turn on short circuit mode.
+    if (! $Reader || isset($Reader->error) ) {
+      $this->short_circuit = true;
+      return;
+    }
+
+    // Caching can be turned off
+    $this->enable_cache = $enable_cache;
+
+    $MAGIC1 = "\x95\x04\x12\xde";
+    $MAGIC2 = "\xde\x12\x04\x95";
+
+    $this->STREAM = $Reader;
+    $magic = $this->read(4);
+    if ($magic == $MAGIC1) {
+      $this->BYTEORDER = 1;
+    } elseif ($magic == $MAGIC2) {
+      $this->BYTEORDER = 0;
+    } else {
+      $this->error = 1; // not MO file
+      return false;
+    }
+
+    // FIXME: Do we care about revision? We should.
+    $revision = $this->readint();
+
+    $this->total = $this->readint();
+    $this->originals = $this->readint();
+    $this->translations = $this->readint();
+  }
+
+  /**
+   * Loads the translation tables from the MO file into the cache
+   * If caching is enabled, also loads all strings into a cache
+   * to speed up translation lookups
+   * 
+   * @access private
+   */
+  function load_tables() {
+    if (is_array($this->cache_translations) &&
+      is_array($this->table_originals) &&
+      is_array($this->table_translations))
+      return;
+
+    /* get original and translations tables */
+    $this->STREAM->seekto($this->originals);
+    $this->table_originals = $this->readintarray($this->total * 2);
+    $this->STREAM->seekto($this->translations);
+    $this->table_translations = $this->readintarray($this->total * 2);
+
+    if ($this->enable_cache) {
+      $this->cache_translations = array ();
+      /* read all strings in the cache */
+      for ($i = 0; $i < $this->total; $i++) {
+        $this->STREAM->seekto($this->table_originals[$i * 2 + 2]);
+        $original = $this->STREAM->read($this->table_originals[$i * 2 + 1]);
+        $this->STREAM->seekto($this->table_translations[$i * 2 + 2]);
+        $translation = $this->STREAM->read($this->table_translations[$i * 2 + 1]);
+        $this->cache_translations[$original] = $translation;
+      }
+    }
+  }
+
+  /**
+   * Returns a string from the "originals" table
+   *
+   * @access private
+   * @param int num Offset number of original string
+   * @return string Requested string if found, otherwise ''
+   */
+  function get_original_string($num) {
+    $length = $this->table_originals[$num * 2 + 1];
+    $offset = $this->table_originals[$num * 2 + 2];
+    if (! $length)
+      return '';
+    $this->STREAM->seekto($offset);
+    $data = $this->STREAM->read($length);
+    return (string)$data;
+  }
+
+  /**
+   * Returns a string from the "translations" table
+   *
+   * @access private
+   * @param int num Offset number of original string
+   * @return string Requested string if found, otherwise ''
+   */
+  function get_translation_string($num) {
+    $length = $this->table_translations[$num * 2 + 1];
+    $offset = $this->table_translations[$num * 2 + 2];
+    if (! $length)
+      return '';
+    $this->STREAM->seekto($offset);
+    $data = $this->STREAM->read($length);
+    return (string)$data;
+  }
+
+  /**
+   * Binary search for string
+   *
+   * @access private
+   * @param string string
+   * @param int start (internally used in recursive function)
+   * @param int end (internally used in recursive function)
+   * @return int string number (offset in originals table)
+   */
+  function find_string($string, $start = -1, $end = -1) {
+    if (($start == -1) or ($end == -1)) {
+      // find_string is called with only one parameter, set start end end
+      $start = 0;
+      $end = $this->total;
+    }
+    if (abs($start - $end) <= 1) {
+      // We're done, now we either found the string, or it doesn't exist
+      $txt = $this->get_original_string($start);
+      if ($string == $txt)
+        return $start;
+      else
+        return -1;
+    } else if ($start > $end) {
+      // start > end -> turn around and start over
+      return $this->find_string($string, $end, $start);
+    } else {
+      // Divide table in two parts
+      $half = (int)(($start + $end) / 2);
+      $cmp = strcmp($string, $this->get_original_string($half));
+      if ($cmp == 0)
+        // string is exactly in the middle => return it
+        return $half;
+      else if ($cmp < 0)
+        // The string is in the upper half
+        return $this->find_string($string, $start, $half);
+      else
+        // The string is in the lower half
+        return $this->find_string($string, $half, $end);
+    }
+  }
+
+  /**
+   * Translates a string
+   *
+   * @access public
+   * @param string string to be translated
+   * @return string translated string (or original, if not found)
+   */
+  function translate($string) {
+    if ($this->short_circuit)
+      return $string;
+    $this->load_tables();
+
+    if ($this->enable_cache) {
+      // Caching enabled, get translated string from cache
+      if (array_key_exists($string, $this->cache_translations))
+        return $this->cache_translations[$string];
+      else
+        return $string;
+    } else {
+      // Caching not enabled, try to find string
+      $num = $this->find_string($string);
+      if ($num == -1)
+        return $string;
+      else
+        return $this->get_translation_string($num);
+    }
+  }
+
+  /**
+   * Sanitize plural form expression for use in PHP eval call.
+   *
+   * @access private
+   * @return string sanitized plural form expression
+   */
+  function sanitize_plural_expression($expr) {
+    // Get rid of disallowed characters.
+    $expr = preg_replace('@[^a-zA-Z0-9_:;\(\)\?\|\&=!<>+*/\%-]@', '', $expr);
+
+    // Add parenthesis for tertiary '?' operator.
+    $expr .= ';';
+    $res = '';
+    $p = 0;
+    for ($i = 0; $i < strlen($expr); $i++) {
+      $ch = $expr[$i];
+      switch ($ch) {
+      case '?':
+        $res .= ' ? (';
+        $p++;
+        break;
+      case ':':
+        $res .= ') : (';
+        break;
+      case ';':
+        $res .= str_repeat( ')', $p) . ';';
+        $p = 0;
+        break;
+      default:
+        $res .= $ch;
+      }
+    }
+    return $res;
+  }
+
+  /**
+   * Get possible plural forms from MO header
+   *
+   * @access private
+   * @return string plural form header
+   */
+  function get_plural_forms() {
+    // lets assume message number 0 is header
+    // this is true, right?
+    $this->load_tables();
+
+    // cache header field for plural forms
+    if (! is_string($this->pluralheader)) {
+      if ($this->enable_cache) {
+        $header = $this->cache_translations[""];
+      } else {
+        $header = $this->get_translation_string(0);
+      }
+      if (eregi("plural-forms: ([^\n]*)\n", $header, $regs))
+        $expr = $regs[1];
+      else
+        $expr = "nplurals=2; plural=n == 1 ? 0 : 1;";
+
+      $this->pluralheader = $this->sanitize_plural_expression($expr);
+    }
+    return $this->pluralheader;
+  }
+
+  /**
+   * Detects which plural form to take
+   *
+   * @access private
+   * @param n count
+   * @return int array index of the right plural form
+   */
+  function select_string($n) {
+    $string = $this->get_plural_forms();
+    $string = str_replace('nplurals',"\$total",$string);
+    $string = str_replace("n",$n,$string);
+    $string = str_replace('plural',"\$plural",$string);
+
+    $total = 0;
+    $plural = 0;
+
+    eval("$string");
+    if ($plural >= $total) $plural = $total - 1;
+    return $plural;
+  }
+
+  /**
+   * Plural version of gettext
+   *
+   * @access public
+   * @param string single
+   * @param string plural
+   * @param string number
+   * @return translated plural form
+   */
+  function ngettext($single, $plural, $number) {
+    if ($this->short_circuit) {
+      if ($number != 1)
+        return $plural;
+      else
+        return $single;
+    }
+
+    // find out the appropriate form
+    $select = $this->select_string($number);
+
+    // this should contains all strings separated by NULLs
+    $key = $single.chr(0).$plural;
+
+
+    if ($this->enable_cache) {
+      if (! array_key_exists($key, $this->cache_translations)) {
+        return ($number != 1) ? $plural : $single;
+      } else {
+        $result = $this->cache_translations[$key];
+        $list = explode(chr(0), $result);
+        return $list[$select];
+      }
+    } else {
+      $num = $this->find_string($key);
+      if ($num == -1) {
+        return ($number != 1) ? $plural : $single;
+      } else {
+        $result = $this->get_translation_string($num);
+        $list = explode(chr(0), $result);
+        return $list[$select];
+      }
+    }
+  }
+
+}
+
+?>

Modified: htdocs/trunk/externals/header.phtml
===================================================================
--- htdocs/trunk/externals/header.phtml	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/externals/header.phtml	2010-05-15 15:42:20 UTC (rev 19175)
@@ -19,7 +19,7 @@
   <link rel="alternate" type="application/atom+xml" title="Atom Feed" href="<?=$top_dir?>/atom.php">
 <?php } ?>
 
-<title><?= _($title); ?> | GnuCash</title>
+<title><?= T_($title); ?> | GnuCash</title>
 </head>
 
 <body>
@@ -30,18 +30,18 @@
 </a>
 <br/>
 <span id="language">
-<?= _("Language"); ?>:
-  <a class="nav" href="<?=$top_dir;?>/en/<?=$current_page;?>">English</a>
-| <a class="nav" href="<?=$top_dir;?>/de/<?=$current_page;?>">Deutsch</a>
-| <a class="nav" href="<?=$top_dir;?>/es/<?=$current_page;?>">Espa&ntilde;ol</a>
-| <a class="nav" href="<?=$top_dir;?>/fr/<?=$current_page;?>">Fran&ccedil;ais</a>
-| <a class="nav" href="<?=$top_dir;?>/it/<?=$current_page;?>">Italiano</a>
-| <a class="nav" href="<?=$top_dir;?>/ja/<?=$current_page;?>">日本語</a> <!-- Japanese -->
-| <a class="nav" href="<?=$top_dir;?>/nl/<?=$current_page;?>">Nederlands</a>
-| <a class="nav" href="<?=$top_dir;?>/nb/<?=$current_page;?>">Norsk Bokm&aring;l</a>
+<?= T_("Language"); ?>:
+  <a class="nav" href="<?=$top_dir;?>/<?=$current_page;?>?lang=en_US">English</a>
+| <a class="nav" href="<?=$top_dir;?>/<?=$current_page;?>?lang=de_DE">Deutsch</a>
+| <a class="nav" href="<?=$top_dir;?>/<?=$current_page;?>?lang=es_ES">Espa&ntilde;ol</a>
+| <a class="nav" href="<?=$top_dir;?>/<?=$current_page;?>?lang=fr_FR">Fran&ccedil;ais</a>
+| <a class="nav" href="<?=$top_dir;?>/<?=$current_page;?>?lang=it_IT">Italiano</a>
+| <a class="nav" href="<?=$top_dir;?>/<?=$current_page;?>?lang=ja_JP">日本語</a> <!-- Japanese -->
+| <a class="nav" href="<?=$top_dir;?>/<?=$current_page;?>?lang=nl_NL">Nederlands</a>
+| <a class="nav" href="<?=$top_dir;?>/<?=$current_page;?>?lang=nb_NO">Norsk Bokm&aring;l</a>
 <!-- | <a class="nav" href="<?=$top_dir;?>/pl/">Polska</a> -->
-| <a class="nav" href="<?=$top_dir;?>/pt_PT/<?=$current_page;?>">Portugu&ecirc;s</a>
-| <a class="nav" href="<?=$top_dir;?>/zh_CN/<?=$current_page;?>">中文</a> <!-- Simplified Chinese -->
+| <a class="nav" href="<?=$top_dir;?>/<?=$current_page;?>?lang=pt_PT">Portugu&ecirc;s</a>
+| <a class="nav" href="<?=$top_dir;?>/<?=$current_page;?>?lang=zh_CN">中文</a> <!-- Simplified Chinese -->
 </span>
 <span id="location">&nbsp; <!-- <?= _("Continent"); ?>:
  (<a class="nav" href="http://www.gnucash.org/">US</a>)

Modified: htdocs/trunk/externals/menu.phtml
===================================================================
--- htdocs/trunk/externals/menu.phtml	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/externals/menu.phtml	2010-05-15 15:42:20 UTC (rev 19175)
@@ -8,38 +8,38 @@
 <div class="othernews">
   <span class="linktop">
     <img class="dot" src="<?=$top_dir?>/externals/webding.png" alt="marker">
-    <b><?= _("Information")?></b>
+    <b><?= T_("Information")?></b>
   </span>
   <ul>
-    <li><a href="<?=$home?>/index.phtml"><?= _("About / News")?></a></li>
-    <li><a href="<?=$home?>/atom.php"><img src="<?=$top_dir?>/externals/feed-icon-12x12.png" width="12" height="12" alt="[atom feed]" /> <?= _("News Feed")?></a></li>
-    <li><a href="<?=$home?>/features.phtml"><?=_("Screenshots, Features")?></a></li>
-    <li><a href="http://wiki.gnucash.org/wiki/Development"><?= _("How to help")?></a></li>
+    <li><a href="<?=$home?>/index.phtml"><?= T_("About / News")?></a></li>
+    <li><a href="<?=$home?>/atom.php"><img src="<?=$top_dir?>/externals/feed-icon-12x12.png" width="12" height="12" alt="[atom feed]" /> <?= T_("News Feed")?></a></li>
+    <li><a href="<?=$home?>/features.phtml"><?=T_("Screenshots, Features")?></a></li>
+    <li><a href="http://wiki.gnucash.org/wiki/Development"><?= T_("How to help")?></a></li>
   </ul>
 </div>
 <div class="othernews">
   <span class="linktop">
     <img class="dot" src="<?=$top_dir?>/externals/webding.png" alt="marker" />
-    <b><?=_("Documentation")?></b></span>
+    <b><?=T_("Documentation")?></b></span>
     <ul>
-      <li><a href="<?=$home?>/docs.phtml"><?=_("Documentation")?></a></li>
-      <li><a href="http://wiki.gnucash.org/wiki/FAQ"><?=_("FAQ")?></a></li>
-      <li><a href="http://wiki.gnucash.org/wiki/"><?=_("Wiki")?></a>&nbsp;
+      <li><a href="<?=$home?>/docs.phtml"><?=T_("Documentation")?></a></li>
+      <li><a href="http://wiki.gnucash.org/wiki/FAQ"><?=T_("FAQ")?></a></li>
+      <li><a href="http://wiki.gnucash.org/wiki/"><?=T_("Wiki")?></a>&nbsp;
       <a href="http://wiki.gnucash.org/wiki/De/GnuCash">[de]</a></li>
-      <li><a href="http://wiki.gnucash.org/wiki/Mailing_Lists"><?=_("Mailing Lists")?></a>
+      <li><a href="http://wiki.gnucash.org/wiki/Mailing_Lists"><?=T_("Mailing Lists")?></a>
       <li style="list-style-image:none;list-style-type:none;"><ul>
-        <li><a href="https://lists.gnucash.org/search/<? if ($lang_dir != "") { echo "$lang_dir/"; } ?>"><?=_("Search")?></a></li>
+        <li><a href="https://lists.gnucash.org/search/<? if ($lang_dir != "") { echo "$lang_dir/"; } ?>"><?=T_("Search")?></a></li>
       </ul></li>
-      <li><a href="http://wiki.gnucash.org/wiki/Bugzilla"><?=_("Bug Reports")?></a></li>
-      <li><a href="http://wiki.gnucash.org/wiki/IRC"><?=_("IRC (Chat)")?></a></li>
-      <li><a href="http://sourceforge.net/donate/index.php?group_id=192"><?=_("Donations")?></a></li>
+      <li><a href="http://wiki.gnucash.org/wiki/Bugzilla"><?=T_("Bug Reports")?></a></li>
+      <li><a href="http://wiki.gnucash.org/wiki/IRC"><?=T_("IRC (Chat)")?></a></li>
+      <li><a href="http://sourceforge.net/donate/index.php?group_id=192"><?=T_("Donations")?></a></li>
     </ul>
 </div>
 <div class="othernews">
   <!-- ?php include("$top_dir/externals/menu-downloads.phtml");? -->
   <span class="linktop">
     <img class="dot" src="<?=$top_dir?>/externals/webding.png" alt="marker" />
-    <b><a href="<?=$home?>/download.phtml"><?=_("Downloads")?></a></b>
+    <b><a href="<?=$home?>/download.phtml"><?=T_("Downloads")?></a></b>
     <ul></ul>
   </span>
 </div>
@@ -47,14 +47,14 @@
   <!-- ?php include("$top_dir/externals/menu-developer.phtml");? -->
   <span class="linktop">
     <img class="dot" src="<?=$top_dir?>/externals/webding.png" alt="marker">
-    <b><?=_("Developer Information")?></b>
+    <b><?=T_("Developer Information")?></b>
   </span>
   <ul>
-    <li><a href="http://svn.gnucash.org/docs/HEAD/"><?=_("Source Docs")?></a></li>
-    <li><a href="http://svn.gnucash.org/trac/browser/"><?= _("Browse Source Code")?></a></li>
-    <li><a href="http://wiki.gnucash.org/wiki/Subversion"><?= _("Subversion Access")?> </a></li>
-    <li><a href="http://wiki.gnucash.org/wiki/Translation"><?=_("Language Translations")?></a></li>
-    <li><a href="<?=$home?>/sizing.phtml"><?=_("Sizing")?></a></li>
+    <li><a href="http://svn.gnucash.org/docs/HEAD/"><?=T_("Source Docs")?></a></li>
+    <li><a href="http://svn.gnucash.org/trac/browser/"><?= T_("Browse Source Code")?></a></li>
+    <li><a href="http://wiki.gnucash.org/wiki/Subversion"><?= T_("Subversion Access")?> </a></li>
+    <li><a href="http://wiki.gnucash.org/wiki/Translation"><?=T_("Language Translations")?></a></li>
+    <li><a href="<?=$home?>/sizing.phtml"><?=T_("Sizing")?></a></li>
   </ul>
 </div>
 </div>

Added: htdocs/trunk/externals/streams.php
===================================================================
--- htdocs/trunk/externals/streams.php	                        (rev 0)
+++ htdocs/trunk/externals/streams.php	2010-05-15 15:42:20 UTC (rev 19175)
@@ -0,0 +1,167 @@
+<?php
+/*
+   Copyright (c) 2003, 2005, 2006, 2009 Danilo Segan <danilo at kvota.net>.
+
+   This file is part of PHP-gettext.
+
+   PHP-gettext is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2 of the License, or
+   (at your option) any later version.
+
+   PHP-gettext is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU General Public License for more details.
+
+   You should have received a copy of the GNU General Public License
+   along with PHP-gettext; if not, write to the Free Software
+   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+
+*/
+
+
+  // Simple class to wrap file streams, string streams, etc.
+  // seek is essential, and it should be byte stream
+class StreamReader {
+  // should return a string [FIXME: perhaps return array of bytes?]
+  function read($bytes) {
+    return false;
+  }
+
+  // should return new position
+  function seekto($position) {
+    return false;
+  }
+
+  // returns current position
+  function currentpos() {
+    return false;
+  }
+
+  // returns length of entire stream (limit for seekto()s)
+  function length() {
+    return false;
+  }
+};
+
+class StringReader {
+  var $_pos;
+  var $_str;
+
+  function StringReader($str='') {
+    $this->_str = $str;
+    $this->_pos = 0;
+  }
+
+  function read($bytes) {
+    $data = substr($this->_str, $this->_pos, $bytes);
+    $this->_pos += $bytes;
+    if (strlen($this->_str)<$this->_pos)
+      $this->_pos = strlen($this->_str);
+
+    return $data;
+  }
+
+  function seekto($pos) {
+    $this->_pos = $pos;
+    if (strlen($this->_str)<$this->_pos)
+      $this->_pos = strlen($this->_str);
+    return $this->_pos;
+  }
+
+  function currentpos() {
+    return $this->_pos;
+  }
+
+  function length() {
+    return strlen($this->_str);
+  }
+
+};
+
+
+class FileReader {
+  var $_pos;
+  var $_fd;
+  var $_length;
+
+  function FileReader($filename) {
+    if (file_exists($filename)) {
+
+      $this->_length=filesize($filename);
+      $this->_pos = 0;
+      $this->_fd = fopen($filename,'rb');
+      if (!$this->_fd) {
+        $this->error = 3; // Cannot read file, probably permissions
+        return false;
+      }
+    } else {
+      $this->error = 2; // File doesn't exist
+      return false;
+    }
+  }
+
+  function read($bytes) {
+    if ($bytes) {
+      fseek($this->_fd, $this->_pos);
+
+      // PHP 5.1.1 does not read more than 8192 bytes in one fread()
+      // the discussions at PHP Bugs suggest it's the intended behaviour
+      $data = '';
+      while ($bytes > 0) {
+        $chunk  = fread($this->_fd, $bytes);
+        $data  .= $chunk;
+        $bytes -= strlen($chunk);
+      }
+      $this->_pos = ftell($this->_fd);
+
+      return $data;
+    } else return '';
+  }
+
+  function seekto($pos) {
+    fseek($this->_fd, $pos);
+    $this->_pos = ftell($this->_fd);
+    return $this->_pos;
+  }
+
+  function currentpos() {
+    return $this->_pos;
+  }
+
+  function length() {
+    return $this->_length;
+  }
+
+  function close() {
+    fclose($this->_fd);
+  }
+
+};
+
+// Preloads entire file in memory first, then creates a StringReader
+// over it (it assumes knowledge of StringReader internals)
+class CachedFileReader extends StringReader {
+  function CachedFileReader($filename) {
+    if (file_exists($filename)) {
+
+      $length=filesize($filename);
+      $fd = fopen($filename,'rb');
+
+      if (!$fd) {
+        $this->error = 3; // Cannot read file, probably permissions
+        return false;
+      }
+      $this->_str = fread($fd, $length);
+      fclose($fd);
+
+    } else {
+      $this->error = 2; // File doesn't exist
+      return false;
+    }
+  }
+};
+
+
+?>

Modified: htdocs/trunk/features.phtml
===================================================================
--- htdocs/trunk/features.phtml	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/features.phtml	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,14 +1,13 @@
 <?php
-$title = _("Features");
-include("local.php");
 include("lang.php");
+$title = T_("Features");
 include("emulate_globals_on.php");
 include("$top_dir/externals/header.phtml");
 include("$top_dir/externals/menu.phtml");
 ?>
 
 <div id="content">
-<h1><?php echo _($title);?></h1>
+<h1><?php echo T_($title);?></h1>
 
 <!-- images needed:
 - register
@@ -19,101 +18,101 @@
 - search query builder?
 -->
 
-<h2><?php echo _("Checkbook-Style Register");?></h2>
+<h2><?php echo T_("Checkbook-Style Register");?></h2>
 
 <p>
 <img src="<?=$top_dir?>/images/features/feature_register.png" width="300" height="200" style="float: right; border: solid thin grey; margin: 0.5em;" alt="[Register]"/>
-<?php echo _("The checkbook-style register provides a custom, convenient and familiar interface to entering financial transactions.   The register supports common checking and credit-card transactions, as well as income, stock and currency transactions.");?>
+<?php echo T_("The checkbook-style register provides a custom, convenient and familiar interface to entering financial transactions.   The register supports common checking and credit-card transactions, as well as income, stock and currency transactions.");?>
 </p>
 <br clear="all"/>
 
-<h2><?php echo _("Double Entry");?></h2>
+<h2><?php echo T_("Double Entry");?></h2>
 <p>
-<?php echo _("Every transaction must debit one account and credit others by an equal amount. This ensures that the \"books balance\": that the difference between income and outflow exactly equals the sum of all assets and equity.");?>
+<?php echo T_("Every transaction must debit one account and credit others by an equal amount. This ensures that the \"books balance\": that the difference between income and outflow exactly equals the sum of all assets and equity.");?>
 </p>
 <br clear="all" />
 
-<h2><?php echo _("Reports, Graphs");?></h2>
+<h2><?php echo T_("Reports, Graphs");?></h2>
 <p>
 <img src="<?=$top_dir?>/images/features/feature_graph-report.png" width="300" height="200" style="float: left; border: solid thin grey; margin: 0.5em;" alt="[Graphs]"/>
-<?php echo _("GnuCash has an integrated reporting and graphing module, and comes complete with a full suite of standard and customizeable reports, such as Balance Sheet, Profit &amp; Loss, Portfolio Valuation, and many others.");?>
+<?php echo T_("GnuCash has an integrated reporting and graphing module, and comes complete with a full suite of standard and customizeable reports, such as Balance Sheet, Profit &amp; Loss, Portfolio Valuation, and many others.");?>
 </p>
 <br clear="all"/>
 
-<h2><?php echo _("Income/Expense Account Types");?></h2>
-<p><?php echo _("Income/Expense Account Types (Categories) allow you to categorize your cash flow.  When used properly with the double-entry feature and equity accounts, these enable you to generate reports, such as Profit &amp; Loss, that plain-vanilla systems cannot handle.");?>
+<h2><?php echo T_("Income/Expense Account Types");?></h2>
+<p><?php echo T_("Income/Expense Account Types (Categories) allow you to categorize your cash flow.  When used properly with the double-entry feature and equity accounts, these enable you to generate reports, such as Profit &amp; Loss, that plain-vanilla systems cannot handle.");?>
 </p>
 <br clear="all" />
 
-<h2><?php echo _("Multiple Currencies");?></h2>
-<p><?php echo _("Different accounts can be denominated in different currencies. Currency movements between accounts are fully balanced when double-entry is enabled.");?>
+<h2><?php echo T_("Multiple Currencies");?></h2>
+<p><?php echo T_("Different accounts can be denominated in different currencies. Currency movements between accounts are fully balanced when double-entry is enabled.");?>
 </p>
 <br clear="all" />
 
-<h2><?php echo _("Stock/Mutual Fund Portfolios");?></h2>
-<p><?php echo _("Track stocks individually (one per account) or in portfolio of accounts (a group of accounts that can be displayed together).");?></p>
+<h2><?php echo T_("Stock/Mutual Fund Portfolios");?></h2>
+<p><?php echo T_("Track stocks individually (one per account) or in portfolio of accounts (a group of accounts that can be displayed together).");?></p>
 <br clear="all" />
 
-<h2><?php echo _("Small Business Accounting Features");?></h2>
+<h2><?php echo T_("Small Business Accounting Features");?></h2>
 <p>
-<?php echo _("Simplify managing a small business with Customer and Vendor tracking, Invoicing and Bill Payment, and Tax and Billing Terms.");?></p>
+<?php echo T_("Simplify managing a small business with Customer and Vendor tracking, Invoicing and Bill Payment, and Tax and Billing Terms.");?></p>
 <br clear="all" />
 
-<h2><?php echo _("QIF Import");?></h2>
-<p><?php echo _("Intuit<sup>&reg;</sup> Quicken<sup>&reg;</sup> QIF files can be imported, and are automatically merged to eliminate duplicate transactions.");?></p>
+<h2><?php echo T_("QIF Import");?></h2>
+<p><?php echo T_("Intuit<sup>&reg;</sup> Quicken<sup>&reg;</sup> QIF files can be imported, and are automatically merged to eliminate duplicate transactions.");?></p>
 <br clear="all" />
 
-<h2><?php echo _("OFX Import");?></h2>
-<p><?php echo _("GnuCash is the first free software application to support the Open Financial Exchange protocol that many banks and financial services are starting to use.");?></p>
+<h2><?php echo T_("OFX Import");?></h2>
+<p><?php echo T_("GnuCash is the first free software application to support the Open Financial Exchange protocol that many banks and financial services are starting to use.");?></p>
 <br clear="all" />
 
-<h2><?php echo _("HBCI Support");?></h2>
-<p><?php echo _("GnuCash is the first free software application to support the German Home Banking Computer Information protocol, allowing German users to perform statement download and initiate bank transfers and direct debits.");?></p>
+<h2><?php echo T_("HBCI Support");?></h2>
+<p><?php echo T_("GnuCash is the first free software application to support the German Home Banking Computer Information protocol, allowing German users to perform statement download and initiate bank transfers and direct debits.");?></p>
 <br clear="all" />
 
-<h2><?php echo _("Improved Import Transaction Matching");?></h2>
-<p><?php echo _("The development of OFX and HBCI support has also resulted in an improved transaction matching system that more accurately recognizes duplicate transactions during file import.");?></p>
+<h2><?php echo T_("Improved Import Transaction Matching");?></h2>
+<p><?php echo T_("The development of OFX and HBCI support has also resulted in an improved transaction matching system that more accurately recognizes duplicate transactions during file import.");?></p>
 <br clear="all" />
 
-<h2><?php echo _("Statement Reconciliation");?></h2>
-<p><?php echo _("A reconcile window with running reconciled and cleared balances makes balancing against bank statements easy.");?></p>
+<h2><?php echo T_("Statement Reconciliation");?></h2>
+<p><?php echo T_("A reconcile window with running reconciled and cleared balances makes balancing against bank statements easy.");?></p>
 <br clear="all" />
 
-<h2><?php echo _("Localization");?></h2>
-<p><?php echo _("Handles internationalized dates and currencies.  The Gnucash menus and popups have been translated to 21 languages, including Chinese, Danish, French, German, Hungarian, Italian, Japanese, Norwegian, Polish, Portuguese, Russian, Spanish, Swedish, Turkish, Ukrainian, and British English. Documentation is available in English, French, Portuguese and Spanish.");?></p>
+<h2><?php echo T_("Localization");?></h2>
+<p><?php echo T_("Handles internationalized dates and currencies.  The Gnucash menus and popups have been translated to 21 languages, including Chinese, Danish, French, German, Hungarian, Italian, Japanese, Norwegian, Polish, Portuguese, Russian, Spanish, Swedish, Turkish, Ukrainian, and British English. Documentation is available in English, French, Portuguese and Spanish.");?></p>
 <br clear="all" />
 
-<h2><?php echo _("Transaction Finder");?></h2>
+<h2><?php echo T_("Transaction Finder");?></h2>
 <p>
 <img src="<?=$top_dir?>/images/features/feature_search.png" width="300" height="200" alt="[Transaction Finder]" style="float: right; margin: 0.5em; border: solid thin grey;"/>
-<?php echo _("A powerful transaction query dialogue can help you quickly locate a needle in a haystack.");?></p>
+<?php echo T_("A powerful transaction query dialogue can help you quickly locate a needle in a haystack.");?></p>
 <br clear="all" />
 
-<h2><?php echo _("General Ledger");?></h2>
-<p><?php echo _("Multiple accounts can be displayed in one register window at the same time. This can ease the trouble of tracking down typing/entry errors. It also provides a convenient way of viewing a portfolio of many stocks, by showing all transactions in that portfolio.");?></p>
+<h2><?php echo T_("General Ledger");?></h2>
+<p><?php echo T_("Multiple accounts can be displayed in one register window at the same time. This can ease the trouble of tracking down typing/entry errors. It also provides a convenient way of viewing a portfolio of many stocks, by showing all transactions in that portfolio.");?></p>
 <br clear="all" />
 
-<h2><?php echo _("Online Stock &amp; Mutual Fund Quotes");?></h2>
-<p><?php echo _("Get Stock &amp; Mutual Fund quotes from various web sites, update portfolio automatically. Additional pricing sources are added regularly.");?></p>
+<h2><?php echo T_("Online Stock &amp; Mutual Fund Quotes");?></h2>
+<p><?php echo T_("Get Stock &amp; Mutual Fund quotes from various web sites, update portfolio automatically. Additional pricing sources are added regularly.");?></p>
 <br clear="all" />
 
-<h2><?php echo _("Check Printing");?></h2>
-<p><?php echo _("Checks may be printed in standard formats on common check stocks. A customization GUI allows custom check layouts to be developed.");?></p>
+<h2><?php echo T_("Check Printing");?></h2>
+<p><?php echo T_("Checks may be printed in standard formats on common check stocks. A customization GUI allows custom check layouts to be developed.");?></p>
 <br clear="all" />
 
 <dl>
-<h2><?php echo _("Scheduled Transactions");?></h2>
-<p><?php echo _("You can now create recurring transactions, including automatic reminders when a transaction is due, the ability to postpone a scheduled transaction without canceling it, and the ability to specify only a limited number of transactions.");?></p>
+<h2><?php echo T_("Scheduled Transactions");?></h2>
+<p><?php echo T_("You can now create recurring transactions, including automatic reminders when a transaction is due, the ability to postpone a scheduled transaction without canceling it, and the ability to specify only a limited number of transactions.");?></p>
 <br clear="all" />
 
-<h2><?php echo _("Mortgage &amp; Loan Repayment Druid");?></h2>
-<p><?php echo _("A guided dialogue for setting up loan payments as scheduled transactions.");?>
+<h2><?php echo T_("Mortgage &amp; Loan Repayment Druid");?></h2>
+<p><?php echo T_("A guided dialogue for setting up loan payments as scheduled transactions.");?>
 </p>
 <br clear="all" />
 
 <!-- fixme: "complete user manual"? -->
-<h2><?php echo _("New User Manual and Help");?></h2>
-<p><?php echo _("A new help subsystem that focuses on how to do tasks is now available, in addition to a Tutorial and Concepts guide that gives the user background information on accounting principles and how they are reflected in GnuCash.");?></p>
+<h2><?php echo T_("New User Manual and Help");?></h2>
+<p><?php echo T_("A new help subsystem that focuses on how to do tasks is now available, in addition to a Tutorial and Concepts guide that gives the user background information on accounting principles and how they are reflected in GnuCash.");?></p>
 <br clear="all" />
 
 </div>

Modified: htdocs/trunk/index.phtml
===================================================================
--- htdocs/trunk/index.phtml	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/index.phtml	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,53 +1,52 @@
 <?php 
 $homepage = true;
-$title = _("Free Accounting Software");
-include("local.php");
 include("emulate_globals_on.php");
 include("lang.php");
+$title = T_("Free Accounting Software");
 include("externals/header.phtml");
 include("externals/menu.phtml"); 
 ?>
 
 <div id="content">
 
-<h1><?php echo _("Welcome to GnuCash.org")?></h1>
+<h1><?php echo T_("Welcome to GnuCash.org")?></h1>
 
 <div id="download">
-<h2><?php printf (_("Download GnuCash %s"), $latest_stable)?></h2>
+<h2><?php printf (T_("Download GnuCash %s"), $latest_stable)?></h2>
 
 <ul>
-<li><img src="<?=$top_dir?>/images/icons/linux.png" /> Linux <a href="<?php echo $download_path.$latest_stable_source;?>"><?php echo _("Source");?></a> | <a href="<?=$home?>/download.phtml#distribution"><?php echo _("Via distribution");?></a></li>
+<li><img src="<?=$top_dir?>/images/icons/linux.png" /> Linux <a href="<?php echo $download_path.$latest_stable_source;?>"><?php echo T_("Source");?></a> | <a href="<?=$home?>/download.phtml#distribution"><?php echo T_("Via distribution");?></a></li>
 <li><img src="<?=$top_dir?>/images/icons/windows.png" /> Microsoft Windows <a href="<?php echo $download_path.$latest_stable_win;?>">XP/Vista/7</a></li>
 <li><img src="<?=$top_dir?>/images/icons/macosx.png" /> Mac OS X <a href="<?php echo $download_path.$latest_stable_mac_intel;?>">Intel</a> | <a href="<?php echo $download_path.$latest_stable_mac_ppc;?>">Power PC</a> | <a href="http://wiki.gnucash.org/wiki/MacOSX/<?php echo $latest_stable;?>/Readme">Readme</a></li>
-<li><a href="<?=$home?>/download.phtml" style="font-size: 80%;"><?=_("More downloads (Source, Development,...)")?></a></li>
+<li><a href="<?=$home?>/download.phtml" style="font-size: 80%;"><?=T_("More downloads (Source, Development,...)")?></a></li>
 </ul>
 </div>
 
-<p><?php echo _("GnuCash is personal and small-business financial-accounting software, freely licensed under the <a href=\"http://www.gnu.org/\">GNU</a> GPL and available for GNU/Linux, BSD, Solaris, Mac OS X and Microsoft Windows.");?></p>
+<p><?php echo T_("GnuCash is personal and small-business financial-accounting software, freely licensed under the <a href=\"http://www.gnu.org/\">GNU</a> GPL and available for GNU/Linux, BSD, Solaris, Mac OS X and Microsoft Windows.");?></p>
 
-<p><?php echo _("Designed to be easy to use, yet powerful and flexible, GnuCash allows you to track bank accounts, stocks, income and expenses.  As quick and intuitive to use as a checkbook register, it is based on professional accounting principles to ensure balanced books and accurate reports. "); ?></p>
+<p><?php echo T_("Designed to be easy to use, yet powerful and flexible, GnuCash allows you to track bank accounts, stocks, income and expenses.  As quick and intuitive to use as a checkbook register, it is based on professional accounting principles to ensure balanced books and accurate reports. "); ?></p>
 
 <div>
-<h2><?php echo _("Feature Highlights"); ?></h2>
+<h2><?php echo T_("Feature Highlights"); ?></h2>
 <div style="float: right">
 <ul>
-<li><?php echo _("QIF/OFX/HBCI Import, Transaction Matching");?></li>
-<li><?php echo _("Reports, Graphs");?></li>
-<li><?php echo _("Scheduled Transactions");?></li>
-<li><?php echo _("Financial Calculations "); ?></li>
+<li><?php echo T_("QIF/OFX/HBCI Import, Transaction Matching");?></li>
+<li><?php echo T_("Reports, Graphs");?></li>
+<li><?php echo T_("Scheduled Transactions");?></li>
+<li><?php echo T_("Financial Calculations "); ?></li>
 </ul>
 </div><div style="border: solid thin white;">
 <ul>
-<li><?php echo _("Double-Entry Accounting");?></li>
-<li><?php echo _("Stock/Bond/Mutual Fund Accounts");?></li>
-<li><?php echo _("Small-Business Accounting");?></li>
-<li><?php echo _("Customers, Vendors, Jobs, <br>Invoices, A/P, A/R");?></li>
+<li><?php echo T_("Double-Entry Accounting");?></li>
+<li><?php echo T_("Stock/Bond/Mutual Fund Accounts");?></li>
+<li><?php echo T_("Small-Business Accounting");?></li>
+<li><?php echo T_("Customers, Vendors, Jobs, <br>Invoices, A/P, A/R");?></li>
 </ul>
 </div>
 </div>
 
 
-<h1><?php echo _("News"); ?></h1>
+<h1><?php echo T_("News"); ?></h1>
 
 <?php
   echo("<!-- top_dir = $top_dir , home = $home -->\n");

Modified: htdocs/trunk/lang.php
===================================================================
--- htdocs/trunk/lang.php	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/lang.php	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,4 +1,11 @@
 <?php
+$top_dir = ".";
+$home = $top_dir;
+$locale_dir = "locale";
+
+# get the cookie setting
+if (array_key_exists('lang_cookie', $_COOKIE)) { $locale = $_COOKIE['lang_cookie']; }
+
 # allow user override.
 if (array_key_exists('lang', $_GET)) { $locale = $_GET["lang"]; }
 
@@ -42,18 +49,21 @@
         $lang_dir = $supported_languages[$locale];
 }
 
+setcookie("lang_cookie", $locale);
+
 # We should have a locale now, let's set up the required bits and pieces to show
 # the website in that language.
-putenv("LANG=$locale");
-putenv("LANGUAGE=$locale");
-$locale_res = setlocale(LC_ALL, "");
+require_once("externals/gettext.inc");
+//putenv("LANG=$locale");
+//putenv("LANGUAGE=$locale");
+$locale_res = T_setlocale(LC_ALL, $locale);
 $domain = "gnucash-htdocs";
-if (! isset($text_dir)) { $text_dir = $top_dir; }
-$dir_res = bindtextdomain($domain, $text_dir);
+if (! isset($text_dir)) { $text_dir = $locale_dir; }
+$dir_res = T_bindtextdomain($domain, $text_dir);
 
 # Also specify that we want to receive the translated strings as UTF-8
-bind_textdomain_codeset($domain, 'UTF-8');
+T_bind_textdomain_codeset($domain, 'UTF-8');
 
-textdomain($domain);
-echo ("<!-- $locale , locale_res [$locale_res] , dir_res $dir_res -->\n");
+T_textdomain($domain);
+echo ("<!-- $locale , locale_res [$locale_res] , dir_res $dir_res, lang_cookie [$lang_cookie] -->\n");
 ?>

Deleted: htdocs/trunk/local.php
===================================================================
--- htdocs/trunk/local.php	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/local.php	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,6 +0,0 @@
-<?php
-#echo ("<!-- top_dir: $top_dir, me: ".__FILE__."-->\n");
-$top_dir = ".";
-$home = $top_dir;
-$locale = "";
-?>

Modified: htdocs/trunk/oldnews.phtml
===================================================================
--- htdocs/trunk/oldnews.phtml	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/oldnews.phtml	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,17 +1,16 @@
 <?php 
-$title = _("Free Accounting Software");
-include("local.php");
 include("emulate_globals_on.php");
 include("lang.php");
+$title = T_("Free Accounting Software");
 include("externals/header.phtml");
 include("externals/menu.phtml");
 ?>
 <div id="content">
 
-<h1><?php echo _("Older Announcements");?></h1>
+<h1><?php echo T_("Older Announcements");?></h1>
 
 <p>
-<?php echo _("This is an archive of announcements that once appeared on the GnuCash home page.");?>
+<?php echo T_("This is an archive of announcements that once appeared on the GnuCash home page.");?>
 </p>
 
 <?php

Modified: htdocs/trunk/search/templates/NMZ.body.php_tmpl
===================================================================
--- htdocs/trunk/search/templates/NMZ.body.php_tmpl	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/search/templates/NMZ.body.php_tmpl	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,11 +1,11 @@
 <?php
 include("lang.php");
 ?>
-<h2><a name="query" id="query"><?=_("Query")?></a></h2>
+<h2><a name="query" id="query"><?=T_("Query")?></a></h2>
 
-<h3><a name="query-term" id="query-term"><?=_("Single term query")?></a></h3>
+<h3><a name="query-term" id="query-term"><?=T_("Single term query")?></a></h3>
 <p>
-<?=_("This query specifies only one term for retrieving all of the
+<?=T_("This query specifies only one term for retrieving all of the
 documents which contain that term, for example:")?>
 </p>
 
@@ -13,10 +13,10 @@
 namazu
 </p>
 
-<h3><a name="query-and" id="query-and"><?=_("AND query")?></a></h3> 
+<h3><a name="query-and" id="query-and"><?=T_("AND query")?></a></h3> 
 
 <p>
-<?=_("This query specifies two or more terms for retrieving all of the
+<?=T_("This query specifies two or more terms for retrieving all of the
 documents which contain both terms. Insert the
 <code class=\"operator\">and</code> operator between the terms, e.g.")?> 
 </p>
@@ -26,13 +26,13 @@
 </p>
 
 <p>
-<?=_("You can omit the <code class=\"operator\">and</code> operator.  Terms which are
+<?=T_("You can omit the <code class=\"operator\">and</code> operator.  Terms which are
 separated by one or more spaces are assumed to be an AND query.")?>
 </p>
 
-<h3><a name="query-or" id="query-or"><?=_("OR query")?></a></h3>
+<h3><a name="query-or" id="query-or"><?=T_("OR query")?></a></h3>
 <p>
-<?=_("This query specifies two or more terms for retrieving all
+<?=T_("This query specifies two or more terms for retrieving all
 documents which contain any one term. Insert the
 <code class=\"operator\">or</code> operator between the terms,
 e.g.")?>
@@ -42,9 +42,9 @@
 Linux or FreeBSD
 </p>
 
-<h3><a name="query-not" id="query-not"><?=_("NOT query")?></a></h3>
+<h3><a name="query-not" id="query-not"><?=T_("NOT query")?></a></h3>
 <p>
-<?=_("This query specifies two or more terms for retrieving all of the
+<?=T_("This query specifies two or more terms for retrieving all of the
 documents which contain a first term but do not contain the
 following terms. Insert the <code class=\"operator\">not</code>
 operator between the terms, for example:")?>
@@ -55,9 +55,9 @@
 </p>
 
 
-<h3><a name="query-grouping" id="query-grouping"><?=_("Grouping")?></a></h3>
+<h3><a name="query-grouping" id="query-grouping"><?=T_("Grouping")?></a></h3>
 <p>
-<?=_("You can group queries by surrounding them by
+<?=T_("You can group queries by surrounding them by
 parentheses. The parentheses should be separated by one or
 more spaces. e.g.")?>
 </p>
@@ -66,9 +66,9 @@
 ( Linux or FreeBSD ) and Netscape not Windows
 </p>
 
-<h3><a name="query-phrase" id="query-phrase"><?=_("Phrase searching")?></a></h3>
+<h3><a name="query-phrase" id="query-phrase"><?=T_("Phrase searching")?></a></h3>
 <p>
-<?=_("You can search for a phrase that consists of two or more terms
+<?=T_("You can search for a phrase that consists of two or more terms
 by surrounding them with double quotation marks or braces such as
 <code class=\"operator\">\"...\"</code> and <code class=\"operator\">{...}</code>.
 In Namazu, the precision of phrase searching is not 100%,
@@ -85,26 +85,26 @@
 </p>
 -->
 
-<h3><a name="query-substring" id="query-substring"><?=_("Substring matching")?></a></h3>
+<h3><a name="query-substring" id="query-substring"><?=T_("Substring matching")?></a></h3>
 <p>
-<?=_("There are three types of searching by substring matching.")?>
+<?=T_("There are three types of searching by substring matching.")?>
 </p>
 
 <dl> 
-<dt><?=_("Prefix matching")?></dt>
-<dd><code class="example">inter*</code> <?=_("(terms which begin with <code>inter</code>)")?></dd>
-<dt><?=_("Inside matching")?></dt>
-<dd><code class="example">*text*</code> <?=_("(terms which contain <code>text</code>)")?></dd>
-<dt><?=_("Suffix matching")?></dt>
+<dt><?=T_("Prefix matching")?></dt>
+<dd><code class="example">inter*</code> <?=T_("(terms which begin with <code>inter</code>)")?></dd>
+<dt><?=T_("Inside matching")?></dt>
+<dd><code class="example">*text*</code> <?=T_("(terms which contain <code>text</code>)")?></dd>
+<dt><?=T_("Suffix matching")?></dt>
 <dd><code class="example">*net</code>
-<?=_("(terms which terminated with <code>net</code>)")?></dd>
+<?=T_("(terms which terminated with <code>net</code>)")?></dd>
 </dl>
 
 
-<h3><a name="query-regex" id="query-regex"><?=_("Regular expressions")?></a></h3>
+<h3><a name="query-regex" id="query-regex"><?=T_("Regular expressions")?></a></h3>
 
 <p>
-<?=_("You can use regular expressions for pattern matching. The
+<?=T_("You can use regular expressions for pattern matching. The
 regular expressions must be surrounded by slashes like <code
 class=\"operator\">/.../</code>. Namazu uses <a
 href=\"http://www.ruby-lang.org/\">Ruby</a>'s regular
@@ -118,9 +118,9 @@
 </p>
 
 
-<h3><a name="query-field" id="query-field"><?=_("Field-specified searching")?></a></h3>
+<h3><a name="query-field" id="query-field"><?=T_("Field-specified searching")?></a></h3>
 <p>
-<?=_("You can limit your search to specific fields such as
+<?=T_("You can limit your search to specific fields such as
 <code>Subject:</code>, <code>From:</code>,
 <code>Message-Id:</code>. This feature is especially convenient for
 Mail/News documents, for example:")?>
@@ -128,58 +128,58 @@
 
 <ul>
 <li><code class="example">+subject:Linux</code><br>
-<?=_("(Retrieves all documents which contain <code>Linux</code>
+<?=T_("(Retrieves all documents which contain <code>Linux</code>
 in a <code>Subject:</code> field)")?>
 </li>
 
 <li><code class="example">+subject:"GNU Emacs"</code><br>
-<?=_("(Retrieves all documents which contain <code>GNU Emacs</code>
+<?=T_("(Retrieves all documents which contain <code>GNU Emacs</code>
 in a <code>Subject:</code> field)")?>
 </li>
 
 <li><code class="example">+from:foo at bar.jp</code><br>
-<?=_("(Retrieves all documents which contain <code>foo at bar.jp</code>
+<?=T_("(Retrieves all documents which contain <code>foo at bar.jp</code>
 in a <code>From:</code> field)")?>
 </li>
 
 
 <li><code class="example">+message-id:&lt;199801240555.OAA18737 at foo.bar.jp&gt;</code><br>
-<?=_("(Retrieves a certain document which contains specified
+<?=T_("(Retrieves a certain document which contains specified
 <code>Message-Id:</code>)")?>
 </li>
 </ul>
 
-<h3><a name="query-notes" id="query-notes"><?=_("Notes")?></a></h3>
+<h3><a name="query-notes" id="query-notes"><?=T_("Notes")?></a></h3>
 
 <ul>
-<li><?=_("In any queries, Namazu ignores case distinctions of
+<li><?=T_("In any queries, Namazu ignores case distinctions of
 alphabet characters; i.e. Namazu does
 case-insensitive pattern matching.")?>
 </li>
 
-<li><?=_("Japanese phrases are automatically segmented into
+<li><?=T_("Japanese phrases are automatically segmented into
 morphemes and are handled as <a
 href=\"#query-phrase\">phrase searching</a>. This process occasionally
 causes invalid segmentation.")?>
 </li>
 
-<li><?=_("Letters, numbers or parts of symbols (duplicated in
+<li><?=T_("Letters, numbers or parts of symbols (duplicated in
 ASCII) which are defined in JIS X 0208 (Japanese
 Industrial Standards) are handled as ASCII characters.")?>
 </li>
 
-<li><?=_("Namazu can handle a term which contains symbols like
+<li><?=T_("Namazu can handle a term which contains symbols like
 <code>TCP/IP</code>.  Since this method of handling isn't complete,
 you can also describe the term as <code>TCP and IP</code> instead of
 <code>TCP/IP</code>, but it may cause noisy results.")?>
 </li>
 
 
-<li><?=_("Substring matching and field-specified searching takes
+<li><?=T_("Substring matching and field-specified searching takes
 more time than other methods.")?>
 </li>
 
-<li><?=_("If you want to use <code class=\"operator\">and</code>,
+<li><?=T_("If you want to use <code class=\"operator\">and</code>,
 <code class=\"operator\">or</code> or <code
 class=\"operator\">not</code> as ordinary keywords<br>
 You can surround them respectively with double quotes like <code

Modified: htdocs/trunk/search/templates/NMZ.foot.php_tmpl
===================================================================
--- htdocs/trunk/search/templates/NMZ.foot.php_tmpl	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/search/templates/NMZ.foot.php_tmpl	2010-05-15 15:42:20 UTC (rev 19175)
@@ -6,13 +6,13 @@
 <div id="tail" style="text-align:center;">
 <hr />
 <p>
-<?=_("This search system is powered by:")?> 
+<?=T_("This search system is powered by:")?> 
 <strong><a href="http://www.namazu.org/">Namazu</a><!-- VERSION --> v <!-- VERSION --></strong>
 </p>
 <p><b>Copyright &copy; 2001-2006 The GnuCash Project</b></p>
-<p><?= _("Server &amp; email outage reports to: ")?>
+<p><?= T_("Server &amp; email outage reports to: ")?>
   <a href="mailto:webmaster at gnucash.org"><b>webmaster at gnucash.org</b></a></p>
-<p><?= _("Translation problems? Contact: <a href=\"mailto:gnucash-devel at gnucash.org\"><b>gnucash-devel at gnucash.org</b></a>");?></p>
+<p><?= T_("Translation problems? Contact: <a href=\"mailto:gnucash-devel at gnucash.org\"><b>gnucash-devel at gnucash.org</b></a>");?></p>
 </div>
 </body>
 </html>

Modified: htdocs/trunk/search/templates/NMZ.head.php_tmpl
===================================================================
--- htdocs/trunk/search/templates/NMZ.head.php_tmpl	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/search/templates/NMZ.head.php_tmpl	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,7 +1,7 @@
 <?php
-$title = _("Mailing List Search");
 $can_utf = false;
 include("lang.php");
+$title = T_("Mailing List Search");
 include("externals/header.phtml");
 include("externals/menu.phtml");
 ?>
@@ -21,18 +21,18 @@
 		   font-weight: bold; }
 --></style>
 <div id="content">
-<h1><?= _($title); ?></h1>
+<h1><?= T_($title); ?></h1>
 
 <form method="get" action="{cgi}">
 <p>
-<strong><?=_("Query")?>:</strong> 
+<strong><?=T_("Query")?>:</strong> 
 <input type="text" name="query" size="40">
-<input type="submit" name="submit" value="<?=_("Search!")?>">
+<input type="submit" name="submit" value="<?=T_("Search!")?>">
 <!-- <input type="hidden" name="idxname" value="foobar"> -->
-<a href="{cgi}"><?=_("[How to search]")?></a>
+<a href="{cgi}"><?=T_("[How to search]")?></a>
 </p>
 <p>
-<strong><?=_("Display")?>:</strong>
+<strong><?=T_("Display")?>:</strong>
 <select name="max">
 <option value="10">10</option>
 <option selected value="20">20</option>
@@ -40,29 +40,29 @@
 <option value="50">50</option>
 <option value="100">100</option>
 </select>
-<strong><?=_("Description")?>:</strong>
+<strong><?=T_("Description")?>:</strong>
 <select name="result">
-<option selected value="normal"><?=_("normal")?></option>
-<option value="short"><?=_("short")?></option>
+<option selected value="normal"><?=T_("normal")?></option>
+<option value="short"><?=T_("short")?></option>
 </select>
-<strong><?=_("Sort")?>:</strong>
+<strong><?=T_("Sort")?>:</strong>
 <select name="sort">
-<option selected value="score"><?=_("by score")?></option>
-<option value="date:late"><?=_("by date in late order")?></option>
-<option value="date:early"><?=_("by date in early order")?></option>
-<option value="field:subject:ascending"><?=_("by title in ascending order")?></option>
-<option value="field:subject:descending"><?=_("by title in descending order")?></option>
-<option value="field:from:ascending"><?=_("by author in ascending order")?></option>
-<option value="field:from:descending"><?=_("by author in descending order")?></option>
-<option value="field:size:ascending"><?=_("by size in ascending order")?></option>
-<option value="field:size:descending"><?=_("by size in descending order")?></option>
-<option value="field:uri:ascending"><?=_("by URI in ascending order")?></option>
-<option value="field:uri:descending"><?=_("by URI in descending order")?></option>
+<option selected value="score"><?=T_("by score")?></option>
+<option value="date:late"><?=T_("by date in late order")?></option>
+<option value="date:early"><?=T_("by date in early order")?></option>
+<option value="field:subject:ascending"><?=T_("by title in ascending order")?></option>
+<option value="field:subject:descending"><?=T_("by title in descending order")?></option>
+<option value="field:from:ascending"><?=T_("by author in ascending order")?></option>
+<option value="field:from:descending"><?=T_("by author in descending order")?></option>
+<option value="field:size:ascending"><?=T_("by size in ascending order")?></option>
+<option value="field:size:descending"><?=T_("by size in descending order")?></option>
+<option value="field:uri:ascending"><?=T_("by URI in ascending order")?></option>
+<option value="field:uri:descending"><?=T_("by URI in descending order")?></option>
 </select>
 </p>
 
 <p>
-<strong><?=_("Lists to Search")?>:</strong>
+<strong><?=T_("Lists to Search")?>:</strong>
 <ul>
 <?php
   if (file_exists("search/templates/NMZtmpl.head.lists.$lang_dir")) {

Modified: htdocs/trunk/search/templates/NMZ.result.normal.php_tmpl
===================================================================
--- htdocs/trunk/search/templates/NMZ.result.normal.php_tmpl	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/search/templates/NMZ.result.normal.php_tmpl	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,9 +1,9 @@
 <?php
 include("lang.php");
 ?>
-<dt>${namazu::counter}. <strong><a href="${uri}">${title}</a></strong> (<?=_("score")?>: ${namazu::score})</dt>
-<dd><strong><?=_("Author")?></strong>: <em>${author}</em></dd>
-<dd><strong><?=_("Date")?></strong>: <em>${date}</em></dd>
+<dt>${namazu::counter}. <strong><a href="${uri}">${title}</a></strong> (<?=T_("score")?>: ${namazu::score})</dt>
+<dd><strong><?=T_("Author")?></strong>: <em>${author}</em></dd>
+<dd><strong><?=T_("Date")?></strong>: <em>${date}</em></dd>
 <dd>${summary}</dd>
 <!-- Translator:  do not translate '${size}' -->
-<dd><a href="${uri}">${uri}</a> <?=_("(\${size} bytes)")?><br><br></dd>
+<dd><a href="${uri}">${uri}</a> <?=T_("(\${size} bytes)")?><br><br></dd>

Modified: htdocs/trunk/search/templates/NMZ.result.short.php_tmpl
===================================================================
--- htdocs/trunk/search/templates/NMZ.result.short.php_tmpl	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/search/templates/NMZ.result.short.php_tmpl	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,6 +1,6 @@
 <?php
 include("lang.php");
 ?>
-<dt>${namazu::counter}. <strong><a href="${uri}">${title}</a></strong> (<?=_("score")?>: ${namazu::score})</dt>
+<dt>${namazu::counter}. <strong><a href="${uri}">${title}</a></strong> (<?=T_("score")?>: ${namazu::score})</dt>
 <!-- Translator:  do not translate '${size}' -->
-<dd><a href="${uri}">${uri}</a> <?=_("(\${size} bytes)")?><br><br></dd>
+<dd><a href="${uri}">${uri}</a> <?=T_("(\${size} bytes)")?><br><br></dd>

Modified: htdocs/trunk/search/templates/NMZ.tips.php_tmpl
===================================================================
--- htdocs/trunk/search/templates/NMZ.tips.php_tmpl	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/search/templates/NMZ.tips.php_tmpl	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,63 +1,63 @@
 <?php
 include("lang.php");
 ?>
-<h2><a name="tips" id="tips"><?=_("Tips on searching")?></a></h2>
+<h2><a name="tips" id="tips"><?=T_("Tips on searching")?></a></h2>
 
 <p>
-<?=_("If you have trouble with searching, you can check the following tips.")?>
+<?=T_("If you have trouble with searching, you can check the following tips.")?>
 </p>
 
 <ul>
-<li><?=_("Check a spelling of your keyword<br>
+<li><?=T_("Check a spelling of your keyword<br>
 Namazu can't find anything with wrong spelling.")?>
 </li>
 
-<li><?=_("Add keywords")?><br>
+<li><?=T_("Add keywords")?><br>
 
-<?=_("If you gained no results or too few results, you can add one
+<?=T_("If you gained no results or too few results, you can add one
 or more related keywords with <code
 class=\"operator\">or</code> operator.  You should get more results.
 e.g.,")?> <br>
 <code class="example">tex or ptex or latex or latex2e</code><br>
 
-<?=_("If you gained too many results, you can add one or more
+<?=T_("If you gained too many results, you can add one or more
 related keywords with <code class=\"operator\">and</code>
 operator. It makes your search more limited. e.g.,")?> <br>
 <code class="example">latex and dvi2ps and eps</code>
 </li>
 
-<li><?=_("Try substring matching")?><br>
+<li><?=T_("Try substring matching")?><br>
 
-<?=_("If you gained no results or too few results, you can try
+<?=T_("If you gained no results or too few results, you can try
 substring matching.")?> 
 
-<?=_("You can specify <code class=\"example\">tex*</code> to
+<?=T_("You can specify <code class=\"example\">tex*</code> to
 search for terms which begin with
 <code>tex</code> (e.g., <code>tex</code>,
 <code>texi2html</code>,
 <code>texindex</code>, <code>text</code>).")?>
 <br>
 
-<?=_("You can specify <code class=\"example\">*tex</code> to
+<?=T_("You can specify <code class=\"example\">*tex</code> to
 search for terms which terminated with <code>tex</code> (e.g.,
 <code>bibtex</code>,
 <code>jlatex</code>, <code>latex</code>,
 <code>platex</code>, <code>ptex</code>, <code>vertex</code>).")?>
 <br>
 
-<?=_("You can specify <code class=\"example\">*tex*</code> to
+<?=T_("You can specify <code class=\"example\">*tex*</code> to
 search for terms which contain <code>tex</code> (many).")?>
 <br>
 </li>
 
-<li><?=_("You tried phrase searching but it hit documents which
+<li><?=T_("You tried phrase searching but it hit documents which
 didn't contain your phrase.")?><br>
 
-<?=_("It's a defect of Namazu. Precision of phrase searching is
+<?=T_("It's a defect of Namazu. Precision of phrase searching is
 not 100%, so it cause wrong results occasionally.")?>
 </li>
 
-<li><?=_("If you want to use <code class=\"operator\">and</code>,
+<li><?=T_("If you want to use <code class=\"operator\">and</code>,
 <code class=\"operator\">or</code> or <code
 class=\"operator\">not</code> as ordinary keywords<br>
 You can surround them respectively with double quotes like <code

Modified: htdocs/trunk/sizing.phtml
===================================================================
--- htdocs/trunk/sizing.phtml	2010-05-15 15:33:27 UTC (rev 19174)
+++ htdocs/trunk/sizing.phtml	2010-05-15 15:42:20 UTC (rev 19175)
@@ -1,6 +1,6 @@
-<?php $title = _("Sizing");
-include("local.php");
+<?php
 include("lang.php");
+$title = T_("Sizing");
 include("emulate_globals_on.php");
 include("externals/header.phtml");
 include("externals/menu.phtml");
@@ -8,56 +8,56 @@
 
 <div id="content">
 
-<h1><?php echo _($title);?></h1>
+<h1><?php echo T_($title);?></h1>
 
 <p>
-<?php echo _("It can often be quite interesting to study the source code metrics behind a software development project.   Not a surprising interest: its accounting afterall.  GnuCash has grown, over the years, from a small handy electronic checkbook to a rather large and multi-featured desktop app.");?>
+<?php echo T_("It can often be quite interesting to study the source code metrics behind a software development project.   Not a surprising interest: its accounting afterall.  GnuCash has grown, over the years, from a small handy electronic checkbook to a rather large and multi-featured desktop app.");?>
 </p>
 <p>
-<?php echo _("GnuCash currently consists of over a third of a million lines of code spread over more than a thousand files.  It has been translated into twenty-three languages and credits over 139 authors and contributors.");?>
+<?php echo T_("GnuCash currently consists of over a third of a million lines of code spread over more than a thousand files.  It has been translated into twenty-three languages and credits over 139 authors and contributors.");?>
 </p>
 <p>
 <img alt="[code size graph]" src="<?=$top_dir?>/images/sizing-graph.png" width="640" height="480" />
 </p>
 <p>
-<?php echo _("If you've had trouble swimming through that mass of source code, think of it this way: printed out on paper, and bound into volumes, it would amount to several dozen copies of Tolstoy's \"War and Peace\", roughly a bookshelf-width's worth of source code.");?>
+<?php echo T_("If you've had trouble swimming through that mass of source code, think of it this way: printed out on paper, and bound into volumes, it would amount to several dozen copies of Tolstoy's \"War and Peace\", roughly a bookshelf-width's worth of source code.");?>
 </p>
 <p>
-<?php echo _("Mind you, this is source code (and docs) crafted and debugged by actual humans, this is *not* autogenerated code.  Tools (such as glade or g-wrap) can generate gaziilions of lines of code automatically; I'm not counting those.  Every last line counted here was typed in, edited, indented, tweaked, multiple times, by human hands.");?>
+<?php echo T_("Mind you, this is source code (and docs) crafted and debugged by actual humans, this is *not* autogenerated code.  Tools (such as glade or g-wrap) can generate gaziilions of lines of code automatically; I'm not counting those.  Every last line counted here was typed in, edited, indented, tweaked, multiple times, by human hands.");?>
 </p>
 <p>
-<?php echo _("Given that we have about 400 outstanding bugs in bugzilla, that works out to about one bug per thousand lines of code, or one bug per 50 pages of printout.  This bug count is actually not atypical for software projects; its near the norm.");?>
+<?php echo T_("Given that we have about 400 outstanding bugs in bugzilla, that works out to about one bug per thousand lines of code, or one bug per 50 pages of printout.  This bug count is actually not atypical for software projects; its near the norm.");?>
 </p>
 <p>
-<?php echo _("The table below shows some historical lines-of-code and number-of-files metrics for the GnuCash development project.  Note that not all of the code is counted: for instance, the Makefiles and configure.in and autogen.sh are not counted. Also, files that are automatically generated are not counted, nor are files that have been 'borrowed' from other projects. Also not counted are experimental files, miscellaneous perl scripts, various converters, addons and utilities.  Finally, <tt>glade</tt> files are not counted, although large parts of the overall GUI are described in <tt>glade</tt> files.");?>
+<?php echo T_("The table below shows some historical lines-of-code and number-of-files metrics for the GnuCash development project.  Note that not all of the code is counted: for instance, the Makefiles and configure.in and autogen.sh are not counted. Also, files that are automatically generated are not counted, nor are files that have been 'borrowed' from other projects. Also not counted are experimental files, miscellaneous perl scripts, various converters, addons and utilities.  Finally, <tt>glade</tt> files are not counted, although large parts of the overall GUI are described in <tt>glade</tt> files.");?>
 </P>
 <P>
-<?php echo _("Note also that KLOC's are not a good metric of programmer productivity, nor even that <code>wc</code> is a good way of counting KLOC's.  Much better measures are complexity metrics, which, for example, count the number and size of if-then-else blocks, or the number and size of all blocks, or the number of math operators per statement.  Maybe someday we'll run one of those tools on this code. For now, this is what we have.  On the other hand, we've attempted to count only those files that contain human-edited code, that is, files that are directly edited by humans.  The point of doing this is to avoid artificially inflating the KLOC counts by counting automatically generated code (which is why the glade files are not counted: they are large and automatically generated).");?>
+<?php echo T_("Note also that KLOC's are not a good metric of programmer productivity, nor even that <code>wc</code> is a good way of counting KLOC's.  Much better measures are complexity metrics, which, for example, count the number and size of if-then-else blocks, or the number and size of all blocks, or the number of math operators per statement.  Maybe someday we'll run one of those tools on this code. For now, this is what we have.  On the other hand, we've attempted to count only those files that contain human-edited code, that is, files that are directly edited by humans.  The point of doing this is to avoid artificially inflating the KLOC counts by counting automatically generated code (which is why the glade files are not counted: they are large and automatically generated).");?>
 </P>
 <P>
 <DIV CLASS="TABLE">
-<P><B><?php echo _("Table 1.  Historical Development Stats");?></B></P>
+<P><B><?php echo T_("Table 1.  Historical Development Stats");?></B></P>
 <TABLE BORDER="1" CLASS="CALSTABLE">
 <THEAD>
 <TR
-><TH ALIGN="LEFT" VALIGN="TOP"><?php echo _("Version");?></TH
+><TH ALIGN="LEFT" VALIGN="TOP"><?php echo T_("Version");?></TH
 ><TH ALIGN="LEFT" VALIGN="TOP">engine</TH
 ><TH ALIGN="LEFT" VALIGN="TOP">backend</TH
 ><TH ALIGN="LEFT" VALIGN="TOP">register</TH
 ><TH ALIGN="LEFT" VALIGN="TOP">ledger</TH
 ><TH ALIGN="LEFT" VALIGN="TOP">motif</TH
 ><TH ALIGN="LEFT" VALIGN="TOP">gnome</TH
-><TH ALIGN="LEFT" VALIGN="TOP"><?php echo _("misc app");?></TH
+><TH ALIGN="LEFT" VALIGN="TOP"><?php echo T_("misc app");?></TH
 ><TH ALIGN="LEFT" VALIGN="TOP">import-export</TH
 ><TH ALIGN="LEFT" VALIGN="TOP">reports</TH
 ><TH ALIGN="LEFT" VALIGN="TOP">scheme</TH
 ><TH ALIGN="LEFT" VALIGN="TOP">business</TH
 ><TH ALIGN="LEFT" VALIGN="TOP">test</TH
 ><TH ALIGN="LEFT" VALIGN="TOP">docs</TH
-><TH ALIGN="LEFT" VALIGN="TOP"><?php echo _("internal txt");?></TH
-><TH ALIGN="LEFT" VALIGN="TOP"><?php echo _("Total");?></TH>
-<TH ALIGN="LEFT" VALIGN="TOP"><?php echo _("Languages");?></TH >
-<TH ALIGN="LEFT" VALIGN="TOP"><?php echo _("Author Credits");?></TH >
+><TH ALIGN="LEFT" VALIGN="TOP"><?php echo T_("internal txt");?></TH
+><TH ALIGN="LEFT" VALIGN="TOP"><?php echo T_("Total");?></TH>
+<TH ALIGN="LEFT" VALIGN="TOP"><?php echo T_("Languages");?></TH >
+<TH ALIGN="LEFT" VALIGN="TOP"><?php echo T_("Author Credits");?></TH >
 </TR>
 </THEAD><TBODY>
 
@@ -316,89 +316,89 @@
 </TBODY ></TABLE ></DIV >
 
  <P>
-<?php echo _("Each cell displays the following:");
+<?php echo T_("Each cell displays the following:");
     
-echo _("number of *c and *.h and *.scm files (KLOCS in *.c + KLOCS in *.h + KLOCS in *.scm).  If there are no *.scm files in the directory, then only (KLOCS in *.c + KLOCS in *.h) are displayed.  If there is only one number in the parenthesis, it is the approriate KLOC count for that statistic.");?>
+echo T_("number of *c and *.h and *.scm files (KLOCS in *.c + KLOCS in *.h + KLOCS in *.scm).  If there are no *.scm files in the directory, then only (KLOCS in *.c + KLOCS in *.h) are displayed.  If there is only one number in the parenthesis, it is the approriate KLOC count for that statistic.");?>
 
  </P><P>
-<?php echo _("where KLOC == kilo-lines-of-code, as reported by <code>wc</code>. As noted above, wc is not a terribly good code metric, but its what we have handy.");?>
+<?php echo T_("where KLOC == kilo-lines-of-code, as reported by <code>wc</code>. As noted above, wc is not a terribly good code metric, but its what we have handy.");?>
 
  </P>
-<b><?php echo _("Table Column Legend");?></b><br><br>
+<b><?php echo T_("Table Column Legend");?></b><br><br>
     <P></P>
  <DL>
     <DT><B>engine</B></DT>
-    <DD><?php echo _("Contents of the src/engine and the include directories. The engine was split out from the motif code in version 1.1. The data storage backend (file-io, sql) was split out in the course of version 1.5");?>
+    <DD><?php echo T_("Contents of the src/engine and the include directories. The engine was split out from the motif code in version 1.1. The data storage backend (file-io, sql) was split out in the course of version 1.5");?>
 	<P></P>
         </DD>
     <DT><B>backend</B></DT>
-    <DD><?php echo _("Contents of the src/backend directory (version 1.7 and later) or of src/engine/file, src/engine/sql (version 1.6 and earlier)");?>
+    <DD><?php echo T_("Contents of the src/backend directory (version 1.7 and later) or of src/engine/file, src/engine/sql (version 1.6 and earlier)");?>
 	<P></P>
         </DD>
     <DT><B>register</B></DT>
-    <DD><?php echo _("Contents of the src/register directory (version 1.6 and earlier) or src/register/register-core (version 1.7 and later).  The register was split out as a separate component from the motif code in version 1.1. As can be seen from the stats, the register code has been fairly stable. At version 1.7 and later, this cell shows a second count: the number of lines of code in src/register/register-gnome (previously counted as part of gnome)");?>
+    <DD><?php echo T_("Contents of the src/register directory (version 1.6 and earlier) or src/register/register-core (version 1.7 and later).  The register was split out as a separate component from the motif code in version 1.1. As can be seen from the stats, the register code has been fairly stable. At version 1.7 and later, this cell shows a second count: the number of lines of code in src/register/register-gnome (previously counted as part of gnome)");?>
 	<P></P>
         </DD>
     <DT><B>ledger</B></DT>
-    <DD><?php echo _("*.c, *.h files in the src directory only (version 1.6 and earlier) or src/register/ledger-core (version 1.7 and later)");?>
+    <DD><?php echo T_("*.c, *.h files in the src directory only (version 1.6 and earlier) or src/register/ledger-core (version 1.7 and later)");?>
 	<P></P>
     </DD>
     <DT><B>motif</B></DT>
-    <DD><?php echo _("Contents of the src/motif directory (version 1.2 and earlier).  The motif version of the code was discontinued after version 1.2, after most of the non-gui code was moved to either the engine, the register or the ledger.");?>
+    <DD><?php echo T_("Contents of the src/motif directory (version 1.2 and earlier).  The motif version of the code was discontinued after version 1.2, after most of the non-gui code was moved to either the engine, the register or the ledger.");?>
 	<P></P>
     </DD>
     <DT><B>gnome</B></DT>
-    <DD><?php echo _("Contents of src/gnome plus src/register/gnome (version 1.6 and earlier). For version 1.7 and later, this consists of src/gnome, src/gnome-search and src/gnome-util");?>
+    <DD><?php echo T_("Contents of src/gnome plus src/register/gnome (version 1.6 and earlier). For version 1.7 and later, this consists of src/gnome, src/gnome-search and src/gnome-util");?>
 	<P></P>
     </DD>
 
-    <DT><B><?php echo _("misc app");?></B></DT>
-    <DD><?php echo _("Contents of miscellanous application-related directories (version 1.7 and later): src/app-file, src/app-utils, src/calculation, src/core-utils, src/gnc-module, src/network-utils, src/tax/us");?>
+    <DT><B><?php echo T_("misc app");?></B></DT>
+    <DD><?php echo T_("Contents of miscellanous application-related directories (version 1.7 and later): src/app-file, src/app-utils, src/calculation, src/core-utils, src/gnc-module, src/network-utils, src/tax/us");?>
 	<P></P>
     </DD>
 
     <DT><B>import-export</B></DT>
-    <DD><?php echo _("Code to import and export various file formats: contents of the src/import-export directory.");?>
+    <DD><?php echo T_("Code to import and export various file formats: contents of the src/import-export directory.");?>
 	<P></P>
      </DD>
 
     <DT><B>reports</B></DT>
-    <DD><?php echo _("Code to generate reports and graphs: contents of the src/reports directory.");?>
+    <DD><?php echo T_("Code to generate reports and graphs: contents of the src/reports directory.");?>
 	<P></P>
      </DD>
 
     <DT><B>scheme</B></DT>
-    <DD><?php echo _("scheme and guile code in directories src/scm plus src/guile (version 1.6 and earlier). In version 1.7 and later, much of this code went into reports, import/export, and into indiovidual modules; thus only miscellaneous code remains.");?>
+    <DD><?php echo T_("scheme and guile code in directories src/scm plus src/guile (version 1.6 and earlier). In version 1.7 and later, much of this code went into reports, import/export, and into indiovidual modules; thus only miscellaneous code remains.");?>
 	<P></P>
     </DD>
 
     <DT><B>business</B></DT>
-    <DD><?php echo _("Code to add small-business features: contents of the src/business directory.");?>
+    <DD><?php echo T_("Code to add small-business features: contents of the src/business directory.");?>
 	<P></P>
      </DD>
 
     <DT><B>test</B></DT>
-    <DD><?php echo _("Code to peform automated regression tests: contents of the src/*/test directories.");?>
+    <DD><?php echo T_("Code to peform automated regression tests: contents of the src/*/test directories.");?>
 	<P></P>
      </DD>
 
     <DT><B>docs</B></DT>
-    <DD><?php echo _("English-language-only user documentation, including on-line help and manual (html, sgml or xml). For version 1.8.4 and later, the number below the bar counts the translated, non-english docs (currently de, es, fr, pt_PT).  Both of these numbers are somewhat hard to count, because of fairly large format churns, and multiple competing versions.");?>
+    <DD><?php echo T_("English-language-only user documentation, including on-line help and manual (html, sgml or xml). For version 1.8.4 and later, the number below the bar counts the translated, non-english docs (currently de, es, fr, pt_PT).  Both of these numbers are somewhat hard to count, because of fairly large format churns, and multiple competing versions.");?>
 	<P></P>
     </DD>
     
-    <DT><B><?php echo _("internal txt");?></B></DT>
-    <DD><?php echo _("The number of design documents and README files aimed at developers. This includes *.txt files, *.texinfo files and README.* files in all subdirectories.  For version 1.7 and later, only those in the src subdirectory are counted (leaving out some half-dozen scattered elsewhere)");?>
+    <DT><B><?php echo T_("internal txt");?></B></DT>
+    <DD><?php echo T_("The number of design documents and README files aimed at developers. This includes *.txt files, *.texinfo files and README.* files in all subdirectories.  For version 1.7 and later, only those in the src subdirectory are counted (leaving out some half-dozen scattered elsewhere)");?>
 	<P></P>
      </DD>
 
-    <DT><B><?php echo _("Languages");?></B></DT>
-    <DD><?php echo _("The number of languages that the application messages have been translated to (the number of <tt>po/*.po</tt> files). In parenthesis, the number of messages in the message files (<tt>grep msgstr po/*.po |wc</tt>), in thousands.");?>
+    <DT><B><?php echo T_("Languages");?></B></DT>
+    <DD><?php echo T_("The number of languages that the application messages have been translated to (the number of <tt>po/*.po</tt> files). In parenthesis, the number of messages in the message files (<tt>grep msgstr po/*.po |wc</tt>), in thousands.");?>
 	<P></P>
     </DD>
     
-    <DT><B><?php echo _("Author Credits");?></B></DT>
-    <DD><?php echo _("The number of people credited in the AUTHORS file (version 1.6 and later) or the README file (earlier versions).  These include lead developers, patch submitters and national-language translators.  This includes additional credits listed in the gnucash-docs/AUTHORS file that are not listed in the main gnucash/AUTHORS file.");?>
+    <DT><B><?php echo T_("Author Credits");?></B></DT>
+    <DD><?php echo T_("The number of people credited in the AUTHORS file (version 1.6 and later) or the README file (earlier versions).  These include lead developers, patch submitters and national-language translators.  This includes additional credits listed in the gnucash-docs/AUTHORS file that are not listed in the main gnucash/AUTHORS file.");?>
 	<P></P>
     </DD>
 </DL>



More information about the gnucash-changes mailing list