Configure supported Languages

From PGVWiki
Jump to navigation Jump to search
Configuration Supported Languages1.jpg

This page is used to control what language choices are available to your users. For example, you can set things up so that only German and French are available. This might be useful if, for example, you are not able to communicate with your users in Hungarian.

You also use this page to alter certain aspects of PhpGedView that depend on the selected language. For example, here is where you tell PhpGedView how to format date and time fields.

The languages that are active and greyed out cannot be disabled because they are in use. Look at the bottom table to see where the language is used. When a language is no longer used by the GEDCOM or user you will be able to disable it.

All of your changes will be recorded in a new file called lang_settings.php created in the ./index/ directory. All of your further changes will be made to this new file and PhpGedView will use only this file. You can revert to the original default language settings by deleting this file.

If you must report problems with your language settings, please tell the PhpGedView support team whether this new file is present or not.

Contextual help is available on every screen; make sure that the Show Contextual Help option in the Help menu is on, and click on a ? next to the subject.

Currently available languates (more may be added in the future) are: Arabic, Chinese, Czech, Danish, English, Estonian, Finnish, French, German, Greek, Hebrew, Hungarian, Italian, Lithuanian, Polish, Portugese (Brasil), Russian, Slovak, Spanish, Spanish (Latin America), Swedish, Turkish, Vietnamese.

Languages Selected

Active languages are shown in the left column. The active checkbox of the default language is not accessible. Additional languages may be activated/deactivated by clicking on the active checkbox. Language files can be edited by clicking on the Edit link.

Edit Individual Language

4 languages 2.jpg


Allow users to select this language if the option Allow user to change language is enabled.

Original name of language in ...

How is this language named in this language?

English calls itself English; German calls itself Deutsch; Dutch calls itself Nederlands; Czech calls itself Ceština, etc.

Abbreviation for language files

This code defines an abbreviation for the language name. This abbreviation forms part of the name of each of the language files used by PhpGedView. For example, the abbreviation used for French is fr, and consequently the file names for French are,,,, and

Language detection codes

These codes allow PhpGedView to detect the Preferred Language setting of the browser being used. PhpGedView determines the language actually being requested by the browser by matching the browser's language code against this list. Individual list entries must be separated by a semicolon.

Flag file

Name of the national flag image file for the selected language.

Images for many countries are available from The WWWeb Factory site.

When you find a flag image you like, right-click on it and save the image in a temporary folder. Next, open the saved image with a suitable image editor (IrfanView is recommended for Windows systems), reduce its size 50x32 pixels, which is the normal size used in PhpGedView, and then save it as a GIF file to the images/flags folder.

Although you can use any name you wish, you should select a name consistent with the two-letter language shortcut. For example, Croatian is represented by the two-letter code hr, so the Croatian flag would normally be named hr.gif.

Date format

This field defines the date format to be used by PhpGedView when displaying dates from the database.

  • Standard format

Symbols you can use are:

     D for day
     M for month
     Y for year.

You can change the order of these symbols, and you can add delimiters to the format. For the examples below, assume that the date in the database is 1965.08.20, which is actually recorded as DATE 20 Aug 1965. The standard setting for the English date display format is D M Y, which produces 20 August 1965. The German date format is usually D. M Y, resulting in 20. August 1965 when displayed by PhpGedView. The eighth month is called "August" in German. In Hungarian, the format normally is Y. M D. producing 1965. augusztus 20. when displayed by PhpGedView. In Hungarian, month names do not have an initial capital letter, and the eighth month is called "augusztus".

  • Alternative format
     To show dates in special ways not handled by the Standard format, use these codes:
     d - day of the month, 2 digits, leading zero; i.e. 01 to 31
     D - day of the week, textual, 3 letters; e.g. Fri
     F - month, textual, long; e.g. January
     j - day of the month, no leading zeros; i.e. 1 to 31
     l (lowercase "L") - day of the week, textual, long; e.g. Friday
     M - month, textual, 3 letters; e.g. Jan
     Y - year, 4 digits; e.g. 1999
     R - French Revolutionary format (see note)
     y - year, 2 digits; e.g. 99

For example, the date format D j F Y could result in Thu 9 January 1806 while the same date displayed according to the formula l d M Y would result in Thursday 09 Jan 1806

  • French Revolutionary format

The format code R works in all languages, but produces output when the date is in the range 1792.09.22 to 1805.12.31. The R code produces only French text, and the order of Day, Month, and Year cannot be changed. The output of the R formatting code is underlined to distinguish it from the regular date.

The R formatting code is considered to be normal text when the date format contains only D, M, and Y codes as described in the topic Standard format above. In other words, for the R code to be recognized, the date format needs to contain a code from the Alternative format list that doesn't appear in the Standard format list.

For example, the date format D M Y R will produce 13 October 1797 R in English for the date 1797.10.13. If, on the other hand, the date format were j F Y R, the same date would result in 13 October 1797 22 Vendemiaire An 6 in English.

Time format

This field defines the time format to be used by PhpGedView.

Symbols you can use are:

     a - lowercase Ante meridiem and Post meridiem; i.e. am or pm
     A - uppercase Ante meridiem and Post meridiem; i.e. AM or PM
     B - Swatch Internet time; i.e. 000 through 999
     c - ISO 8601 date (added in PHP 5); e.g. 2004-02-12T15:19:21+00:00
     d - day of the month, 2 digits, leading zero; i.e. 01 to 31
     D - day, textual, three letters; e.g. Mon
     F - month, textual, long; e.g. January
     g - hour, 12-hour format, no leading zero; i.e. 1 through 12
     G - hour, 24-hour format, no leading zero; i.e. 0 through 23
     h - hour, 12-hour format, leading zero; i.e. 01 through 12
     H - hour, 24-hour format, leading zero; i.e. 00 through 23
     i - minutes, leading zero; i.e. 00 to 59
     I (capital "i") - daylight saving time indicator; 1 if Daylight Saving Time, 0 otherwise.
     j - day of the month, no leading zero; i.e. 1 to 31
     l (lowercase "L") - day of the week, textual, long; e.g. Friday
     L - leap year indicator; 1 if it is a leap year, 0 otherwise. 
     m - month, numeric, leading zero; i.e. 01 through 12
     M - month, textual, 3 letters; e.g. Jan
     n - month, numeric, no leading zero; i.e. 1 through 12
     O (capital "o") - difference between local and Greenwich time (GMT) in hours; e.g. +0200
     r - RFC 2822 formatted date; e.g. Thu, 21 Dec 2000nbsp;16:01:07 +0200
     s - seconds, leading zero; i.e. 00 through 59
     S - day of the month suffix, English only, 2 characters; i.e. st, nd, rd or th. Works well with j
     t - number of days in the given month; i.e. 28 through 31
     T - time zone setting of this machine; e.g. CEST, EST, MDT
     U - seconds since the start of the Unix Epoch (January 1 1970 00:00:00 GMT)
     w - day of the week, numeric; i.e. 0 (for Sunday) through 6 (for Saturday)
     W - ISO-8601 week number of year, weeks starting on Monday; e.g. 42 (the 42nd week in the year)
     Y - year, 4 digits; e.g. 1999
     y - year, 2 digits; e.g. 99
     z - day of year, numeric, no leading zeros; i.e. 0 (1 Jan) through 364 (31 Dec when not a leap year) or 365 (31 Dec in leap years)
     Z - time zone offset in seconds. The offset for time zones west of Greenwich is always negative, and for those east of Greenwich the offset is always positive. i.e. -43200 through 43200

You can change the order of these symbols, and you can add delimiters to the format.

For example, in German this field normally contains H:i:s to produce a display like 09:01:25. English usually defines the time format as g:i:sa to produce a display like 9:01:25am.

In the 24-hour system, midnight is 00:00. In the 12-hour system, midnight is 12:00am and noon is 12:00pm.

Week starting day

The day of the week that starts a new week in this language. Most languages start the week on Sunday, but some start on Monday or other days.

Text direction

Identifies which direction is used to write text in the chosen language. Most languages are written from left to right. Arabic and Hebrew are examples of languages that are written in the opposite direction (right to left).

Surname first

In some languages the surname should be displayed first instead of the default to display it last. Enabling this option will display the surname first. Hungarian, Chinese, and Japanese are examples where the surname (the family name) is usually given first.

Alphabet upper case

Upper case alphabet letters in this language. This alphabet is used while sorting lists of names.

Alphabet lower case

Lower case alphabet letters in this language. This alphabet is used while sorting lists of names.

Language files

PhpGedView has implemented support for many different languages. This has been achieved by keeping all text that is visible to users in files completely separate from the main program. There is a set of five files for each supported language, and the various texts have been separated into one of these files according to function. When a given text is not yet available in translated form, PhpGedView will use the English version.

The files in each language set are (xx stands for the language two-letter code):

  • admin.xx.php This file contains terms and common expressions for use during the administration of PhpGedView and the genealogical databases.
  • configure_help.xx.php This file contains terms, common expressions, and Help text for use during configuration of PhpGedView. The Help text is not intended to be viewed by ordinary users.
  • countries.xx.php This is a list of country names, taken from the Web site of the Statistics Division, United Nations Department of Economic and Social Affairs. This is the relevant link to the English list. The list is available in either English or French.
  • editor.xx.php This file contains terms and common expressions for use during the editing of entries in the genealogical databases.
  • facts.xx.php This file contains the textual equivalents of the GEDCOM Fact codes found in the GEDCOM 5.5.1 Standard. It also contains additional Fact codes not found in the Standard but used by various genealogy programs. An English copy of the GEDCOM 5.5.1 Standard can be downloaded in PDF (Portable Document Format).
  • faqlist.xx.php This file is a set of frequently asked questions that have been collected by the PhpGedView development team. Each FAQ has two entries in this file. One entry is the FAQ heading (usually the question), and the other is the FAQ body (usually the answer). Replacements for the faqlist.xx.php files, which are updated frequently, may be downloaded from the PhpGedView home site. See also Writing FAQ's in multiple languages
  • help_text.xx.php This file contains Help text for ordinary users. Some Help topics in this file address the needs of Administrators, and are hidden from users who do not have Admin rights.
  • lang.xx.php Many terms and common expressions are found in this file.
  • extra.xx.php This file is always loaded after all the others and provides a means whereby a site administrator can override or alter any standard text in the selected language. It can also be used to provide a title for the genealogical databases that varies according to the currently active language. The contents of this additional file are completely up to the site administrator; this file will never be distributed with any version of PhpGedView. The administrator should never make changes to the standard language files; all local changes should be concentrated in this optional file.