Merge #1780 SSL 선택적 사용시 XEDITION 레이아웃의 로그인 팝업에 SSL이 적용되지 않는 문제 수정 by kijin

* pr/1780:
  SSL 선택적 사용시 XEDITION 레이아웃의 로그인 팝업에 SSL이 적용되지 않는 문제 수정
This commit is contained in:
Kijin Sung 2015-10-14 14:41:50 +09:00
commit 4cbf201cbd
2 changed files with 14 additions and 2 deletions

View file

@ -471,6 +471,18 @@ function getFullSiteUrl()
return $url;
}
/**
* Return the exact url of the current page
*
* @return string
*/
function getCurrentPageUrl()
{
$protocol = $_SERVER['HTTPS'] == 'on' ? 'https://' : 'http://';
$url = $protocol . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];
return htmlspecialchars($url, ENT_COMPAT, 'UTF-8', FALSE);
}
/**
* Return if domain of the virtual site is url type or id type
*

View file

@ -446,9 +446,9 @@
<h1>LOGIN</h1>
</div>
<div class="login-body">
<form action="{getUrl()}" method="post" autocomplete="off">
<form action="{getUrl('', 'act', 'procMemberLogin')}" method="post" autocomplete="off">
<input type="hidden" name="act" value="procMemberLogin" />
<input type="hidden" name="success_return_url" value="{htmlspecialchars(getRequestUriByServerEnviroment(), ENT_COMPAT | ENT_HTML401, 'UTF-8', FALSE)}" />
<input type="hidden" name="success_return_url" value="{getCurrentPageUrl()}" />
<input type="hidden" name="xe_validator_id" value="layouts/xedition/layout/1" />
<fieldset>
<legend class="blind">{$lang->cmd_login}</legend>