[% PROCESS elements.html %]
[% INCLUDE input element_data = { name = "username" type = "hidden" value = user.login }; INCLUDE input element_data = { name = "company" type = "hidden" value = user.company }; password_strings = "title:'" _ text("Change Password") _ "', old password:'" _ text("Old Password") _ "', new password:'" _ text("New password") _ "', verify:'" _ text("Verify") _ "', change:'" _ text("Change Password") _ "', no-oldpw:'" _ text("No Old Password") _ "', strength:'" _ text("Strength"); %]

[% text('Preferences for [_1]',user.login) %]
[% IF request.action == 'save_preferences' %]
[% text('Preferences Saved') %]
[% END # if action %]
[% IF user.password_expires.years ; ALERT = text("Warning: Your password will expire in [_1] years", user.password_expires.years); ELSIF user.password_expires.months ; ALERT = text("Warning: Your password will expire in [_1] months", user.password_expires.months); ELSIF user.password_expires.weeks ; ALERT = text("Warning: Your password will expire in [_1] weeks", user.password_expires.weeks); ELSIF user.password_expires.days ; ALERT = text("Warning: Your password will expire in [_1] days", user.password_expires.days); ELSE ; ALERT = text("Warning: Your password will expire today"); END; %] [% ALERT %]
[% text('Settings') %]
[% text('Date Format') %] | [% PROCESS select element_data={ name = 'dateformat' options = user.dateformats default_values = [ user.prefs.dateformat ] text_attr = 'format' value_attr = 'format' } %]
[% text('Number Format') %] | [% PROCESS select element_data={ name = 'numberformat' options = user.numberformats default_values = [ user.prefs.numberformat ] text_attr = 'format' value_attr = 'format' } %]
[% text('Language') %] | [% PROCESS select_language element_data={ name = 'language' options = user.language_codes default_values = [ user.prefs.language ] text_attr = 'label' value_attr = 'id' default_blank = 1 required = 'required' }%]
[% text('Stylesheet') %] | [% PROCESS select element_data={ name = 'stylesheet' options = user.cssfiles default_values = [ user.prefs.stylesheet ] text_attr = 'file' value_attr = 'file' } %]
[% IF PRINTERS.defined %]
[% text('Printer') %] | [% PROCESS select element_data={ name = 'printer' options = PRINTERS default_values = [ user.prefs.printer] }%]
[% END %]

[% PROCESS button element_data = { type = "submit" class = "submit" name = "__action" value = "save_preferences" text = text('Save') } %]