Changeset 549
- Timestamp:
- 11/11/08 14:59:58 (15 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/phpgwapi/templates/celepar/navbar.inc.php
r547 r549 243 243 $agreeterm_url = $_SERVER['HTTP_HOST'] . $GLOBALS['phpgw_info']['server']['webserver_url'] . '/preferences/termo_aceite.php'; 244 244 245 if ($GLOBALS['phpgw_info']['server']['use_https'] > 0)245 if ($GLOBALS['phpgw_info']['server']['use_https'] == 2) 246 246 $agreeterm_url = 'https://' . $agreeterm_url; 247 247 else -
trunk/preferences/termo_aceite.php
r547 r549 10 10 * option) any later version. * 11 11 \**************************************************************************/ 12 ini_set("display_errors","1");13 14 12 $GLOBALS['phpgw_info']['flags'] = array( 15 13 'noheader' => True, … … 31 29 $GLOBALS['phpgw']->template->set_var('No',lang('No')); 32 30 $GLOBALS['phpgw']->template->set_var('url_accept',lang('Change')); 33 $GLOBALS['phpgw']->template->set_var('url_dont_accept',' /logout.php');31 $GLOBALS['phpgw']->template->set_var('url_dont_accept','../logout.php'); 34 32 $GLOBALS['phpgw']->template->set_var('do you agree with the terms?',lang('Do you agree with the terms?')); 35 33 … … 38 36 if (isset($_POST['pass'])) 39 37 { 40 $ldapManager = CreateObject('contactcenter.bo_ldap_manager');41 $srcs = $ldapManager->get_all_ldap_sources();42 38 $common = CreateObject('phpgwapi.common'); 39 // For Write operations in LDAP, the ldap master values (from Setup) must be verified. 40 // If you dont use Ldap replication, ignore it. 41 if ( (!empty($GLOBALS['phpgw_info']['server']['ldap_master_host'])) && 42 (!empty($GLOBALS['phpgw_info']['server']['ldap_master_root_dn'])) && 43 (!empty($GLOBALS['phpgw_info']['server']['ldap_master_root_pw']))) { 44 45 $ldap =$common->ldapConnect($GLOBALS['phpgw_info']['server']['ldap_master_host'], 46 $GLOBALS['phpgw_info']['server']['ldap_master_root_dn'], 47 $GLOBALS['phpgw_info']['server']['ldap_master_root_pw'],false); 48 } 49 else 50 // For Write operations in LDAP, use ldapConnect without parameters. 51 $ldap =$common->ldapConnect(); 43 52 44 /*echo $srcs[1]['host']."----".$srcs[1]['dn']."----".$srcs[1]['pw']; 45 exit(0);*/ 46 47 $ldap =$common->ldapConnect($srcs[1]['host'],$srcs[1]['acc'],$srcs[1]['pw'],false); 48 49 53 50 54 $ldap_mod_replace['phpgwAgreeTerm'] = 1; 51 55 $dn = $GLOBALS['phpgw_info']['user']['account_dn']; 52 56 53 57 ldap_mod_replace ( $ldap, $dn, $ldap_mod_replace ); 54 58 55 59 header("location: ../home.php?cd=yes"); 56 60 }
Note: See TracChangeset
for help on using the changeset viewer.