Return-Path: Delivered-To: apmail-xml-cocoon-cvs-archive@xml.apache.org Received: (qmail 64689 invoked by uid 500); 1 Nov 2002 13:18:30 -0000 Mailing-List: contact cocoon-cvs-help@xml.apache.org; run by ezmlm Precedence: bulk Reply-To: cocoon-dev@xml.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list cocoon-cvs@xml.apache.org Received: (qmail 64680 invoked by uid 500); 1 Nov 2002 13:18:30 -0000 Delivered-To: apmail-xml-cocoon2-cvs@apache.org Date: 1 Nov 2002 13:18:26 -0000 Message-ID: <20021101131826.14107.qmail@icarus.apache.org> From: shannon@apache.org To: xml-cocoon2-cvs@apache.org Subject: cvs commit: xml-cocoon2/src/documentation/xdocs/howto howto-i18n-xmlform.xml X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N shannon 2002/11/01 05:18:26 Modified: src/documentation/xdocs/howto howto-i18n-xmlform.xml Log: General edits for grammar and readability. Revision Changes Path 1.3 +97 -71 xml-cocoon2/src/documentation/xdocs/howto/howto-i18n-xmlform.xml Index: howto-i18n-xmlform.xml =================================================================== RCS file: /home/cvs/xml-cocoon2/src/documentation/xdocs/howto/howto-i18n-xmlform.xml,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- howto-i18n-xmlform.xml 1 Nov 2002 13:17:12 -0000 1.2 +++ howto-i18n-xmlform.xml 1 Nov 2002 13:18:26 -0000 1.3 @@ -2,7 +2,7 @@
- How to Use i18n Transformer with XMLForm Framework + i18n within the XMLForm Framework @@ -12,29 +12,28 @@

-This How-To shows you how to use the i18n for web site Internationalization with XMLForm Framework. -It requires prior knowledge of Cocoon XMLForm,XSLT,Schematron and i18n. +This How-To shows you how to use the i18n for web site internationalization with the XMLForm Framework. +It requires prior knowledge of Cocoon XMLForm, XSLT, Schematron, and i18n.

-You will learn how to build a simple Login XMLForm and use i18n to make it multiLanguage-enabeled. -this How-To teaches you how to build this Form by yourself. Thus, you will get a better feel -of how Cocoon XMLForm really works with i18n. +You will learn how to build a simple Login XMLForm and use i18n to make it multi-language enabled. +This How-To teaches you how to build this form. Thus, you will get a better feel +for how Cocoon XMLForm really works with i18n.

-Cocoon users who want to learn how to use the i18n for web site Internationalization with XMLForm Framework . +Cocoon users who want to learn how to use the i18n for web site internationalization with the XMLForm Framework.

-

Here's what you need:

-

Cocoon must be running on your system. The steps below have been tested with Cocoon 2.1-dev .

+

Cocoon must be running on your system. The steps below have been tested with Cocoon 2.1-dev.

You will need the following:

    @@ -48,9 +47,10 @@ build -Dinclude.webapp.libs=true webapp -

    You will need to understand and be familiar with XSL,i18n,XForms, XPath, Schematron. If you +

    You will need to understand and be familiar with XSL, i18n, XForms, XPath, and Schematron. If you are unfamiliar with these technologies, it is advised that you learn - such concepts first.

    + these related concepts first. If you are unfamiliar with XMLForm, check out the +XMLForm Wizard How-To first.

    @@ -95,36 +95,35 @@

    -Create the Schematron validation file general-schema.xml and insert the following validation Pattern for the Login XMLForm

    +Create the Schematron validation file general-schema.xml and insert the following validation pattern for the Login XMLForm.

    -Below is a snippt code of this Pattern:

    +Here is a snippet of this pattern:

    - - - Email format is invalid. - - - - - The Password Should be @ least 8 character. - - + + + Email format is invalid. + + + + + The Password Should be @ least 8 characters. + + ]]>
    - +

    -create a simple XSLT stylesheet file to match the Violation tag in the XMLForm file and put it in the sitemap after the XMLForm Transformer. - the code of this stylesheet is as follow : +Create a simple XSLT stylesheet file to match the violation element in the XMLForm file, and place it in the sitemap after the XMLForm Transformer. The code of this stylesheet is as follows:

    + xmlns:xsl="http://www.w3.org/1999/XSL/Transform" + xmlns:xf="http://xml.apache.org/cocoon/xmlform/2002" + xmlns:i18n="http://apache.org/cocoon/i18n/2.0"> @@ -149,36 +148,41 @@ ]]> -Basically this snippet is matching the Violation tag on the form file and apply the i18n translation on the -resulting error messages if there is any violation on the entered data. +Basically this snippet is matching the violation element on the form file. If any violations on the entered data occur, it applies the i18n translation on the resulting error messages.
    - +

    -create the Cataloge file that contain your error messages and all what you want to be translated. - a code snippet of the catalog file is as follow: +Create the catalog file that contains your error messages and all what you want to be translated. Here is a snippet from the catalog file:

    + - - Email Address - Password - Login - - - Email format is invalid. - The Password Should be at least 8 character. + + Email Address + Password + Login + + + + Email format is invalid. + + + The Password Should be at least 8 characters. + ]]> -

    also the second language Cataloge file is as follow (for e.g German) :

    +

    Here is a snippet from a second catalog language file, in this case, for German:

    + +Do we need an entity for the character in the German translation of invalid? @@ -191,46 +195,52 @@ Login - Email-format ist ungültig. - Das Passwort sollte wenigsten 8 Zeichen haben.[translated message] + + Email-format ist ungültig. + + + Das Passwort sollte wenigsten 8 Zeichen haben.[translated message] + ]]>
    - +

    -Here we reach to the end of this How To by putting the sitemap snippet of this sample: +Now we reach to the end of this How-To by showing the sitemap snippet for this sample:

    - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + ]]> -
    @@ -238,8 +248,8 @@

    -This How To now enable you to use i18n Transformer and XMLForm Framewrok and also the Translation of the Violation Error messages resulted from the Shematron Validation. -I hope you're beginning to see that you find this How To simple and easy to follow. +This How-To enables you to use i18n Transformer and XMLForm Framework as well as to translate any violation error messages resulting from Shematron validation. +I hope you have found this How-To easy to follow.

    @@ -274,6 +284,22 @@ Mohamed El-Refaey.

    + + +

    +10-30-02: First version contributed by Mohamed El-Refaey. +

    +

    +10-31-02: "Real" German translations added by Michael Enke. +

    +

    +10-31-02: Revised by Mohamed El-Refaey to clarify examples. +

    +

    +11-01-02: Edited by Diana Shannon. +

    +
    + ---------------------------------------------------------------------- In case of troubles, e-mail: webmaster@xml.apache.org To unsubscribe, e-mail: cocoon-cvs-unsubscribe@xml.apache.org For additional commands, e-mail: cocoon-cvs-help@xml.apache.org