mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-03 16:51:40 +09:00
Fix inconsistent path for lang_type cookie
Context::setLangType()에서 생성하는 lang_type 쿠키와 자바스크립트 setLangType()에서 생성하는 lang_type 쿠키의 path가 달라 라이믹스를 서브폴더에 설치한 경우 충돌이 일어나는 문제 해결
This commit is contained in:
parent
fcfb89edea
commit
b5cdd1212e
1 changed files with 5 additions and 1 deletions
|
|
@ -759,7 +759,11 @@ function doChangeLangType(obj) {
|
|||
}
|
||||
}
|
||||
function setLangType(lang_type) {
|
||||
XE.cookie.set("lang_type", lang_type, { path: "/", expires: 3650 });
|
||||
var baseurl = XE.URI(default_url).pathname();
|
||||
if (baseurl !== '/') {
|
||||
XE.cookie.remove('lang_type', { path: '/' });
|
||||
}
|
||||
XE.cookie.set('lang_type', lang_type, { path: baseurl, expires: 365 });
|
||||
}
|
||||
|
||||
/* 미리보기 */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue