Changeset 4828 for trunk/preferences
- Timestamp:
- 07/19/11 16:54:27 (13 years ago)
- Location:
- trunk/preferences
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/preferences/preferences.php
r3018 r4828 22 22 if ($_POST['cancel']) 23 23 { 24 24 $GLOBALS['phpgw']->redirect_link('/preferences/index.php'); 25 25 } 26 26 … … 29 29 $default = get_var('default',Array('POST')); 30 30 31 if(!@is_object($GLOBALS['phpgw']->js)) 32 { 33 $GLOBALS['phpgw']->js = CreateObject('phpgwapi.javascript'); 34 } 35 $GLOBALS['phpgw']->js->validate_file('jscode','validate','preferences'); 36 31 37 $t = CreateObject('phpgwapi.Template',$GLOBALS['phpgw']->common->get_tpl_dir('preferences')); 32 38 $t->set_file(array( 33 39 'preferences' => 'preferences.tpl' 34 40 )); 41 42 43 35 44 $t->set_block('preferences','list','lists'); 36 45 $t->set_block('preferences','row','rowhandle'); … … 43 52 $GLOBALS['phpgw']->translation->add_app('preferences'); // we need the prefs translations too 44 53 } 54 55 $GLOBALS['phpgw']->preferences->default['expressoMail']['show_name_print_messages'] = "0"; 45 56 46 57 /* Make things a little easier to follow */ … … 205 216 { 206 217 global $t,$prefs; 207 $t->set_var('row_id', "${GLOBALS[type]}[$name]");218 $t->set_var('row_id', "${GLOBALS[type]}[$name]"); 208 219 $t->set_var('row_value',$code.$prefs[$name].$appendcode); 209 220 $t->set_var('row_name',lang("signature")); … … 240 251 } 241 252 $s .= create_option_string($default,$values); 253 242 254 if ($GLOBALS['type'] == 'user') 243 255 { … … 346 358 { 347 359 $_appname = check_app(); 348 349 360 $prefs = &$repository[$_appname]; 350 361 … … 487 498 if (!is_admin() || $error) 488 499 { 489 $GLOBALS['phpgw']->redirect_link('/'.$_GET['appname'].'/'); 500 $GLOBALS['phpgw']->redirect_link('/'.$_GET['appname'].'/'); 490 501 } 491 502 … … 513 524 $t->set_var('messages',$error); 514 525 $t->set_var('action_url',$GLOBALS['phpgw']->link('/preferences/preferences.php','appname=' . $_GET['appname'])); 515 $t->set_var('th_bg', $GLOBALS['phpgw_info']['theme']['th_bg']); 526 527 if($_GET['appname'] == 'expressoMail1_2') 528 $t->set_var('validateForm','onSubmit="return validateSignature();"'); 529 530 $t->set_var('th_bg', $GLOBALS['phpgw_info']['theme']['th_bg']); 516 531 $t->set_var('th_text',$GLOBALS['phpgw_info']['theme']['th_text']); 517 532 $t->set_var('row_on', $GLOBALS['phpgw_info']['theme']['row_on']); -
trunk/preferences/templates/default/preferences.tpl
r1405 r4828 1 1 <center><b>{messages}</b></center> 2 2 <!-- BEGIN form --> 3 <form method="POST" action="{action_url}" >3 <form method="POST" action="{action_url}" {validateForm}> 4 4 <table width="75%" cellpadding=0 cellspacing=0 class="prefTable"> 5 5 <tr><td colspan="3">{tabs}</td></tr>
Note: See TracChangeset
for help on using the changeset viewer.