GnuCash website.
HTML PHP CSS Perl6 JavaScript ApacheConf Other
Switch branches/tags
Nothing to show
Permalink
Failed to load latest commit information.
externals Adjust Windows download link. Mar 28, 2017
images Remove the bitcoin tip jar as it should no longer be maintained. Apr 14, 2017
locale
news
po update # program translations and separate it from translatable text May 10, 2017
search Fix insecure image and don't try to https the doc nightlies from code. Mar 5, 2016
.gitignore
.htaccess
2.6-release-tour.phtml
Makefile Add a comment to Makefile, where to find languages May 9, 2017
README Mini change to test www sync Mar 31, 2014
accept-to-gettext.inc making gettext available in all files and moving more files beneath www Jan 23, 2006
atom.php Synchronize beta with trunk Nov 24, 2012
browserconfig.xml Squash annoying IE on Win 8 browser config request errors Feb 17, 2014
develdocs.phtml Drop svn repo references in favour of git repo. Jan 26, 2014
docs.phtml
donate.phtml
download.phtml Point to right wiki page for building instructions. Dec 19, 2016
emulate_globals_on.php
favicon.ico
features.phtml update # program translations and separate it from translatable text May 10, 2017
index.phtml Revert "Change all URLs pointing to gnucash.org to https." Mar 5, 2016
info.php restore old info.php output. May 25, 2006
lang.php Fix a typo in a comment May 9, 2017
oldnews.phtml Merge beta branch, fix some typos, merge latest translation template:… Sep 25, 2011
robots.txt Update robot.txt Oct 11, 2016
rss-feed.phtml The apache htaccess redirects don't seem to be working. Jun 21, 2006
sizing.phtml Fix a typo. Feb 22, 2013
viewdoc.phtml ... and add pt to trunk_langs Feb 11, 2017

README

# -- rst --

TODO

  • re-work page content for new-style translations (one big block) - re-flow existing po-file content.
  • update features screenshots
  • fix double-slash on langdir='' mlist search menu URLs

Notes about multi-lingual gnucash website content

  • all pages must call lang.php to bring in gettext support.
  • It would be nice to use the same containing structure for all translations.
  • Phrase content can probably be po-style translated well.
  • Body/paragraph content probably wants to be block-replaced.
  • We're fine not doing auto-language negotiation.

www.gnucash.org coding conventions/notes

There are three main classes of links:

  • external resources [$top_dir[/externals]] - www: relative - !www: relative

  • translations [$top_dir/[<lang>]] - www: relative - !www: relative

  • navigation [$home] - www: relative - !www: url-prefixed ("http://www.gnucash.org/file.phtml")

    www.gnucash.org | lists.gnucash.org |

    external (C) | ./[externals/] | ./[externals/] |

    external (lang) | ../[externals/] | ../[externals/] | ,- $top_dir translation (C) | ./[lang] | ./[lang] | /

    translation (lang) | ../[lang] | ../[lang] | /

    navigation (C) | ./ | http://www.[...]/ | ,- $home

    navigation (lang) | ./ | http://www.[...]/[lang]/ | /

As such:

$top_dir := the relative reference to the top of the relative website; this
should be used for language-independent resources (stylesheets, images, php includes), but not for links...
$home := a prefix for navigational URLs; for everything but
lists.gnucash.org, this'll be ".", but for lists.gnucash.org it'll be "http://www.gnucash.org/".

As well, the following variables should be set:

  • per directory:

    $locale := the LANG to use for gettext.

  • per file:

    $title := the text of the page.

    $homepage := if the file is the homepage; controls RSS feed linkage.

Note about folders

  • "externals" folder contains images linked to external sources (e.g. logo_w120.png is used on the wiki and packtpub_gnucash_2.4cov.png is linked to the external book website)
  • "docs" is supposed to hold copies of the compiled documentation (html, pdf, epub,...) This used to be a version managed directory inside this repository. It has been moved into a separate repository in 2014. The php website code still assumes this directory to exist though. So in order to satisfy this code a softlink should be set up on the webserver: docs->"real location of compiled docs"

Preparing translations

First, make sure the pot file is up to date. You can do that by running the command:

$ make pot

Now merge the new content into your translation, substituting the name of your po file in the command:

$ msgmerge po/en_GB.po po/gnucash-htdocs.pot -o po/en_GB.po

Finally, see the size of the task ahead:

$ msgfmt -c --statistics po/en_GB.po

Whilst editing the translation, run the msgfmt command from time to time to catch errors and let you know how much is left to do.

When you come across fuzzy markers: (#, fuzzy), check whether the proposed translation is a valid translation. If it is, then remove the fuzzy marker. If it is not, either edit the translation and remove the fuzzy marker, or leave the fuzzy marker where it is -- this message will then be treated as untranslated.

When you have no fuzzy and no untranslated messages, update the binary translation file for your locale:

$ make de [fr nl ...]

Which will build an individual translation, or:

$ make mos

Which will make all the known translations.

Publishing the website

Changes that are committed to 'trunk' are published automatically. No other steps are required.

Website beta environment

Some changes may be too drastic or experimental to push to the public website. There is a beta website available as well on

http://www.gnucash.org/beta/

To work in this beta environment, checkout the beta branch from svn:

svn checkout http://svn.gnucash.org/repo/htdocs/branches/beta htdocs-beta

WARNING: this branch is currently not kept in sync with trunk. So if you
intend to experiment with the current conten in trunk, please ask one of the devs to merge the current trunk to beta first !