diff --git a/admin/login.php b/admin/login.php index 3c49bd36..e51d5789 100644 --- a/admin/login.php +++ b/admin/login.php @@ -4,7 +4,7 @@ include 'common.php'; if ($user->hasLogin()) { $response->redirect($options->adminUrl); } -$rememberName = htmlspecialchars(\Typecho\Cookie::get('__typecho_remember_name')); +$rememberName = htmlspecialchars(\Typecho\Cookie::get('__typecho_remember_name', '')); \Typecho\Cookie::delete('__typecho_remember_name'); $bodyClass = 'body-100'; @@ -25,7 +25,7 @@ include 'header.php';

- +

@@ -43,7 +43,7 @@ include 'menu.php';

+ name="text" class="w-100 mono">text ?? ''); ?>

diff --git a/admin/write-post.php b/admin/write-post.php index 896b4b00..1f9a40a8 100644 --- a/admin/write-post.php +++ b/admin/write-post.php @@ -38,7 +38,7 @@ include 'menu.php'; $post->cid, $post->category, $post->year, $post->month, $post->day ], $permalink); } - $input = ''; + $input = ''; ?>

@@ -47,7 +47,7 @@ include 'menu.php';

+ name="text" class="w-100 mono">text ?? ''); ?>

@@ -134,7 +134,7 @@ include 'menu.php'; + value="password"password ?? '') > 0): ?> selected> @@ -142,7 +142,7 @@ include 'menu.php'; value="waiting"pass('editor', true) || $post->status == 'waiting'): ?> selected>

-

password) == 0): ?> class="hidden"> +

password ?? '') == 0): ?> class="hidden"> response->redirect(defined('__TYPECHO_ADMIN__') ? $this->options->loginUrl . - (0 === strpos($this->request->getReferer(), $this->options->loginUrl) ? '' : + (0 === strpos($this->request->getReferer() ?? '', $this->options->loginUrl) ? '' : '?referer=' . urlencode($this->request->makeUriByRequest())) : $this->options->siteUrl, false); } }