From 270282e3a26b21184a2051995cb5b9a2755b823d Mon Sep 17 00:00:00 2001 From: wei <> Date: Sat, 18 Feb 2006 23:41:16 +0000 Subject: Update some javascript code. --- demos/quickstart/protected/pages/Advanced/I18N.page | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'demos/quickstart/protected/pages/Advanced/I18N.page') diff --git a/demos/quickstart/protected/pages/Advanced/I18N.page b/demos/quickstart/protected/pages/Advanced/I18N.page index 1bb5a9a0..db97c25c 100644 --- a/demos/quickstart/protected/pages/Advanced/I18N.page +++ b/demos/quickstart/protected/pages/Advanced/I18N.page @@ -134,6 +134,9 @@ $message = localize("There are {num_users} users online.", array('num_users'=>$n

Where the second parameter in localize takes an associative array with the key as the substitution to find in the text and replaced it with the associated value. The localize function does not solve the problem of localizing languages that have plural forms, the solution is to use TChoiceFormat.

+

The following sample demonstrates the basics of localization in Prado.

+ +

I18N Components

TTranslate

@@ -225,4 +228,5 @@ is "One Apple". If the Value was "2", then it will show "Two Apples".Any non-empty combinations of the delimiters of square and round brackets are acceptable. The string chosen for display depends on the Value property. The Value is evaluated for each set until the Value is found to belong to a particular set.

+ \ No newline at end of file -- cgit v1.2.3