[Mailman-Users] Default Languages
Mark Sapiro
msapiro at value.net
Mon Jun 11 01:55:31 CEST 2007
Mark Sapiro wrote:
>
>To address the confirmation page, you could apply the following patch
>to Mailman/Cgi/confirm.py
>
>--- Mailman/Cgi/confirm.py 2007-05-07 15:34:26.593750000 -0700
>+++ Mailman/Cgi/confirmx.py 2007-06-08 08:47:46.000000000 -0700
>@@ -66,8 +66,12 @@
> return
>
> # Set the language for the list
>- i18n.set_language(mlist.preferred_language)
>- doc.set_language(mlist.preferred_language)
>+ try:
>+ p_l = mlist.default_user_language
>+ except NameError:
>+ p_l = mlist.preferred_language
>+ i18n.set_language(p_l)
>+ doc.set_language(p_l)
Sorry, brain cramp. The above patch won't quite do. It needs to be
--- Mailman/Cgi/confirm.py 2007-05-07 15:34:26.593750000 -0700
+++ Mailman/Cgi/confirmx.py 2007-06-08 08:47:46.000000000 -0700
@@ -66,8 +66,12 @@
return
# Set the language for the list
- i18n.set_language(mlist.preferred_language)
- doc.set_language(mlist.preferred_language)
+ try:
+ p_l = mlist.default_user_language
+ except AttributeError:
+ p_l = mlist.preferred_language
+ i18n.set_language(p_l)
+ doc.set_language(p_l)
I.e., the exception if the list doesn't have a default_user_language
attribute is AttributeError, not NameError.
Sorry for any confusion.
--
Mark Sapiro <msapiro at value.net> The highway is for gamblers,
San Francisco Bay Area, California better use your sense - B. Dylan
More information about the Mailman-Users
mailing list