|
|
@@ -70,33 +70,22 @@ const PageCreateModal = (props) => {
|
|
|
setTemplate(value);
|
|
|
}
|
|
|
|
|
|
- /**
|
|
|
- * encode except slashes
|
|
|
- */
|
|
|
- function encodeExceptSlashes(path) {
|
|
|
- return path
|
|
|
- .split('/')
|
|
|
- .map(item => encodeURIComponent(item))
|
|
|
- .join('/');
|
|
|
- }
|
|
|
/**
|
|
|
* access today page
|
|
|
*/
|
|
|
function createTodayPage() {
|
|
|
let tmpTodayInput1 = todayInput1;
|
|
|
- const tmpTodayInput2 = encodeExceptSlashes(todayInput2);
|
|
|
if (tmpTodayInput1 === '') {
|
|
|
tmpTodayInput1 = t('Memo');
|
|
|
}
|
|
|
- tmpTodayInput1 = encodeExceptSlashes(tmpTodayInput1);
|
|
|
- window.location.href = urljoin(userPageRootPath, tmpTodayInput1, now, tmpTodayInput2, '#edit');
|
|
|
+ window.location.href = encodeURI(urljoin(userPageRootPath, tmpTodayInput1, now, todayInput2, '#edit'));
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* access input page
|
|
|
*/
|
|
|
function createInputPage() {
|
|
|
- window.location.href = urljoin(encodeExceptSlashes(pageNameInput), '#edit');
|
|
|
+ window.location.href = encodeURI(urljoin(pageNameInput, '#edit'));
|
|
|
}
|
|
|
|
|
|
function ppacInputChangeHandler(value) {
|