Changeset 3486 for branches/2.2
- Timestamp:
- 11/10/10 12:57:43 (14 years ago)
- Location:
- branches/2.2/phpgwapi
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2.2/phpgwapi/inc/class.sessions.inc.php
r3430 r3486 405 405 { 406 406 // Use HTTP_X_FORWARDED_HOST if set, which is the case behind a none-transparent proxy 407 $this->cookie_domain = isset($_SERVER['HTTP_X_FORWARDED_HOST']) ? $_SERVER['HTTP_X_FORWARDED_HOST'] : $_SERVER['HTTP_HOST']; 407 //$this->cookie_domain = isset($_SERVER['HTTP_X_FORWARDED_HOST']) ? $_SERVER['HTTP_X_FORWARDED_HOST'] : $_SERVER['HTTP_HOST']; 408 //Modificacao feita para que o Expresso redirecione para o primeiro proxy caso haja um encadeamento de mais de um proxy. 409 $this->cookie_domain = nearest_to_me(); 408 410 409 411 // remove port from HTTP_HOST -
branches/2.2/phpgwapi/inc/common_functions.inc.php
r3437 r3486 706 706 } 707 707 708 /*! 709 @function nearest_to_me 710 @abstract return host nearest to client 711 @Include by Serpro ( Antonio Carlos da Silva). 712 */ 713 function nearest_to_me() 714 { 715 $proxies=explode(',',$_SERVER['HTTP_X_FORWARDED_HOST']); 716 return isset($_SERVER['HTTP_X_FORWARDED_HOST']) ? $proxies[0] : $_SERVER['HTTP_HOST']; 717 } 718 708 719 /*! 709 720 @function session_convert -
branches/2.2/phpgwapi/templates/default/login.tpl
r3480 r3486 40 40 newScreenX = screen.width - newWidth; 41 41 newScreenY = 0; 42 Window1=window.open( link,'',"width="+newWidth+",height="+newHeight+",screenX="+newScreenX+",left="+newScreenX+",screenY="+newScreenY+",top="+newScreenY+",toolbar=no,scrollbars=yes,resizable=no");42 Window1=window.open('{dir_root}'+link,'',"width="+newWidth+",height="+newHeight+",screenX="+newScreenX+",left="+newScreenX+",screenY="+newScreenY+",top="+newScreenY+",toolbar=no,scrollbars=yes,resizable=no"); 43 43 } 44 44 var opened = false, vkb = null, text = null; -
branches/2.2/phpgwapi/templates/default/login_default.php
r3480 r3486 198 198 list($forward,$extra_vars) = explode('?',$forward,2); 199 199 } 200 if ($GLOBALS['phpgw_info']['server']['use_https'] != 2) 201 { 202 $forward = 'http://'.$_SERVER['HTTP_HOST'].($GLOBALS['phpgw']->link($forward.'?cd=yes')); 203 echo "<script language='Javascript1.3'>location.href='".$forward."'</script>"; 204 } 205 else 206 { 207 $GLOBALS['phpgw']->redirect_link($forward,$extra_vars); 200 if ($GLOBALS['phpgw_info']['server']['use_https'] != 2) 201 { 202 //Modificacao feita para que o Expresso redirecione para o primeiro proxy caso haja um encadeamento de mais de um proxy. 203 //$forward = 'http://'.$_SERVER['HTTP_HOST'].($GLOBALS['phpgw']->link($forward.'?cd=yes')); 204 $forward = 'http://' . nearest_to_me() . $GLOBALS['phpgw']->link($forward.'?cd=yes'); 205 echo "<script language='Javascript1.3'>location.href='".$forward."'</script>"; 206 } 207 else 208 { 209 $GLOBALS['phpgw']->redirect_link($forward,$extra_vars); 208 210 } 209 211 } … … 363 365 $tmpl->set_var('website_title', $GLOBALS['phpgw_info']['server']['site_title']); 364 366 $tmpl->set_var('template_set',$GLOBALS['phpgw_info']['login_template_set']); 365 366 include_once(dirname( __FILE__ ) . '/../../../infodist/ultima-revisao-svn.php');367 if(isset($ultima_revisao)) $tmpl->set_var('ultima_rev','<br>' . $ultima_revisao);368 367 369 368 $GLOBALS['phpgw']->translation->add_app('loginhelp',$_GET['lang']); … … 539 538 540 539 540 $tmpl->set_var('dir_root', 'http://' . nearest_to_me() . '/'); 541 include_once(dirname( __FILE__ ) . '/../../../infodist/ultima-revisao-svn.php'); 542 if(isset($ultima_revisao)) $tmpl->set_var('ultima_rev','<br>' . $ultima_revisao); 541 543 $tmpl->pfp('loginout','login_form'); 542 544 ?> -
branches/2.2/phpgwapi/templates/default/navbar.inc.php
r3338 r3486 278 278 $GLOBALS['phpgw_info']['user']['lastpasswd_change'] < $aux) 279 279 { 280 $changepasswd_url = $_SERVER['HTTP_HOST'] . $GLOBALS['phpgw_info']['server']['webserver_url'] . '/preferences/changepassword.php?cd=1';281 280 //$changepasswd_url = $_SERVER['HTTP_HOST'] . $GLOBALS['phpgw_info']['server']['webserver_url'] . '/preferences/changepassword.php?cd=1'; 281 $changepasswd_url = nearest_to_me() . '/preferences/changepassword.php?cd=1'; 282 282 if ($GLOBALS['phpgw_info']['server']['use_https'] > 0) 283 283 $changepasswd_url = 'https://' . $changepasswd_url;
Note: See TracChangeset
for help on using the changeset viewer.