|
Class: I18n
Source Location: Program_Root/I18n/I18n.php
I18n is a class that makes it easier to add multiple language support to PHP programs. It is lightweight and not very sophisticated, attempting to keep it straight-forward while emulating some of the more elegant features of other internationalization systems, such as gettext.
Author(s)
Version
- 3.0, 2003-04-20, $Id: I18n.php,v 1.3 2005/12/29 22:04:54 lux Exp $
Copyright
- Copyright (C) 2001-2003, Simian Systems Inc.
|
|
|
Child Classes
|
Inherited Variables
|
Inherited Methods
|
Class Details
Class Variables
$charset = 'iso-8859-1'
[line 183]
The charset of the current language, which can be used to tell the browser, or any language-aware PHP functions, which to use.
Tags:
$cookieName = 'sitellite_lang_pref'
[line 218]
$directory =
[line 146]
The location of the language files.
Tags:
$error =
[line 227]
If an error occurs during any portion of this class, this will contain the message.
Tags:
$fallbacks = array ()
[line 208]
Contains fallback text replacements.
Tags:
$fullname = ''
[line 191]
The full name of language in use (ie. 'English' for 'en').
Tags:
$language =
[line 129]
The language code, corresponding to the name of the language file.
Tags:
$languages = array ()
[line 216]
2-D list of available languages, retrieved from getLanguages().
Tags:
$lang_hash = array ()
[line 164]
The language hash, a key/value list.
Tags:
$load_new = false
[line 174]
Determines whether getIndex() should call include() or include_once() to retrieve the language keys. Default is false, which calls include_once().
Tags:
$locale =
[line 138]
The locale code, corresponding to the name of the country to localize numbers and dates for.
Tags:
$method = 'metaphone'
[line 200]
The method to use to create the $lang_hash keys. Can be 'metaphone', 'md5', and 'plain'.
Tags:
$page =
[line 156]
The name of the current page, which can be used in the language file in a switch statement to keep the $lang_hash array shorter, instead of loading more than is necessary.
Tags:
Class Methods
|
|