[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Fle3-dev] Error in language editing user info

From: janne . pietarila
Subject: Re: [Fle3-dev] Error in language editing user info
Date: Mon, 3 Mar 2003 18:25:39 +0200
User-agent: Mutt/1.2.5i

On Mon, Mar 03, 2003 at 04:34:25PM +0100, Fabrizio Reale wrote:
> When entering the edit user info page I found that it always show me
> english as the selected language.
> Even if the language worked correctly in the other pages.
> I have corrected the problem by changing in the edit_user_form.dtml line
> 127 column 111 "language" with "get_language()".

It works OK for me. Line 127 splitted to several lines:

<option value="<dtml-var sequence-key>"
 <dtml-try language>
  <dtml-unless expr="_['sequence-key'] != language">selected</dtml-unless>
  <dtml-unless new>
   <dtml-unless expr="_['sequence-key'] != get_language()">selected
><dtml-var sequence-item></option>

The variable language should be set only when a user has given invalid
input and is returned to the form (in that case information is read from 
variable so that user's input is not lost...) So normally we get 
exception and go to branch that uses get_language().

Which version of Fle3 you are running? Does the bug occur when you
are editing your own user information or some other user's information?

> Besides this I have found that in UserInfo.py (in CVS) line 372 is
> written "langauge" instead of "language".
> And finally a question to understand. Why there are two set_language
> defined in UserInfo.py?

Thank you for noticing this bug. We had two versions of get_language()
and set_language() methods, and the first version of set_language()
was using "langauge" instead of "language". Luckily, Python seems
to use the last definition (does anyone know if this is in specification,
or just in current implementation?).

I just committed to CVS UserInfo.py with bad versions of get_language() 
and set_language() removed.

Janne Pietarila

reply via email to

[Prev in Thread] Current Thread [Next in Thread]