Index: openacs-4/packages/acs-lang/www/change-locale-include.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-lang/www/change-locale-include.tcl,v diff -u -r1.19.2.2 -r1.19.2.3 --- openacs-4/packages/acs-lang/www/change-locale-include.tcl 14 Oct 2019 16:48:16 -0000 1.19.2.2 +++ openacs-4/packages/acs-lang/www/change-locale-include.tcl 15 Oct 2019 06:17:47 -0000 1.19.2.3 @@ -37,15 +37,15 @@ {package_id:naturalnum(hidden) {value $package_id} } - {return_url:text(hidden) + {return_url:text(hidden) {value $return_url} } {site_wide_locale:oneof(select),multiple,optional {label "[_ acs-lang.Your_Preferred_Locale]"} {options $list_of_locales} {values "[ad_conn locale]"} {help_text "[_ acs-lang.Your_locale_site_wide]"} - } + } } @@ -81,40 +81,40 @@ } } -# Setup of form elements done, now add the action blocks +# Setup of form elements done, now add the action blocks ad_form \ -extend \ -name locale \ -on_request { if { $package_level_locales_p } { set package_level_locale [lang::user::package_level_locale $package_id] } - + set site_wide_locale [lang::user::site_wide_locale] if { $site_wide_locale eq "" } { set site_wide_locale [lang::system::site_wide_locale] } - + if { $use_timezone_p } { set timezone [lang::user::timezone] if { $timezone eq "" } { set timezone [lang::system::timezone] } - } + } } \ -on_submit { lang::user::set_locale $site_wide_locale - + if { $package_level_locales_p } { lang::user::set_locale -package_id $package_id $package_level_locale } - + if { $use_timezone_p } { lang::user::set_timezone $timezone } ad_returnredirect $return_url - ad_script_abort + ad_script_abort } # Local variables: