Results 1 to 4 of 4

Thread: Date Zimlet Translation

  1. #1
    Join Date
    Feb 2006
    Posts
    92
    Rep Power
    10

    Default Date Zimlet Translation

    Hi,
    im translating the Zimlet to recognize Spanish dates formats, the zimlet is almost finished, but im having problems with this REGEX:

    var $RE_NEXT_THIS_LAST = "(pr\u00f3ximo|este|\u00faltimo)";

    as you see, \u00faltimo = último, but the regex engine is not matching this word, truly the regex engine its not matching any word that starts with an UTF-8 cacharacter.

    any ideas?
    Patricio Bruna
    http://www.itlinux.cl

  2. #2
    Join Date
    Jul 2006
    Location
    Stuttgart / Germany
    Posts
    223
    Rep Power
    9

    Default

    Quote Originally Posted by pbruna View Post
    Hi,
    im translating the Zimlet to recognize Spanish dates formats, the zimlet is almost finished, but im having problems with this REGEX:

    var $RE_NEXT_THIS_LAST = "(pr\u00f3ximo|este|\u00faltimo)";

    as you see, \u00faltimo = último, but the regex engine is not matching this word, truly the regex engine its not matching any word that starts with an UTF-8 cacharacter.

    any ideas?
    Hi,

    I can confirm that. It seem impossible to match a word starting with a UTF-8 character. Did you find a solution or a workaround for that?

    Thanks and Regards
    Thomas

  3. #3
    Join Date
    Feb 2006
    Posts
    92
    Rep Power
    10

    Default neither

    I could not resolve this issue.
    Patricio Bruna
    http://www.itlinux.cl

  4. #4
    Join Date
    Jul 2006
    Location
    Stuttgart / Germany
    Posts
    223
    Rep Power
    9

    Default

    Quote Originally Posted by pbruna View Post
    I could not resolve this issue.
    But in the meanwhile I could :-)

    The problem is not the UTF-8 char in the beginning of the word, but the word boundary "\b" metacharacter.

    The "\b" apperently matches the first byte of the UTF-8 character preventing the remaining regexp to match against the word.

    You can verify this when you remove the first "\\b" in your ZmDateES2ObjectHandler.REGEX:

    ZmDateES2ObjectHandler.REGEX = new RegExp( $RE_NEXT_THIS_LAST + $RE_SP + $RE_DOW + "\\b", "ig");

    This works for me. But maybe there is a better solution to this...

    Regards
    Thomas

Similar Threads

  1. Replies: 21
    Last Post: 02-04-2010, 10:06 AM
  2. Zimbra fails after working for 2 weeks
    By Linsys in forum Administrators
    Replies: 10
    Last Post: 10-07-2008, 01:42 AM
  3. Zimlet translation & adaptation
    By Klug in forum I18N/L10N - Translations
    Replies: 5
    Last Post: 01-31-2008, 02:52 AM
  4. Post instsallation problems
    By Assaf in forum Installation
    Replies: 14
    Last Post: 01-29-2007, 11:38 AM
  5. Date Zimlet speaks French
    By cvidal in forum I18N/L10N - Translations
    Replies: 4
    Last Post: 10-20-2006, 03:32 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •