Skip to content

Commit

Permalink
Fix:文章加密再优化
Browse files Browse the repository at this point in the history
  • Loading branch information
ZigZagK committed May 31, 2020
1 parent 5440410 commit 182c53d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ function themeInit($archive){
Helper::options()->commentsMarkdown=true;
Helper::options()->commentsAntiSpam=false;
Helper::options()->commentsCheckReferer=false;
if ($archive->hidden) header('HTTP/1.1 200 OK');
if ($archive->hidden && ($_SERVER['REQUEST_METHOD']=='POST' || $_SERVER['HTTP_X_PJAX']=='true')) header('HTTP/1.1 200 OK');
$gets=$_GET;$posts=$_POST;$salt=Helper::options()->apisalt;$type=$gets['type'];
if ($type=='settingbackup'){
$opt=$gets['opt'];$db=Typecho_Db::get();
Expand Down
4 changes: 2 additions & 2 deletions js/MDUI2333.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ function ExSearchCall(item){ //ExSearch插件PJAX跳转
}
}
function showannouncement(msg,pos){ //显示公告
if (msg!=null && pos!=null) announcement=mdui.snackbar({message:msg,position:pos,closeOnOutsideClick:false,buttonText:'OK',buttonColor:'#fff',timeout:0,onOpen:function(){$('.mdui-snackbar').addClass('mdui-color-theme')}});
if (msg!=null && pos!=null) announcement=mdui.snackbar({message:msg,position:pos,buttonText:'OK'});
}
function highlightinit(mode){ //代码高亮初始化
if (mode=='highlightjs') hljs.initHighlightingOnLoad();
Expand Down Expand Up @@ -198,7 +198,7 @@ function ajaxcomment(options){ //AJAX评论
highlightreload(highlightmode,'#commentcontent');smoothscroll('.haveat a');mdui.mutation();
$('html,body').animate({scrollTop:$(target).offset().top},'fast');
animatecss(target,'fadeInRight','0.5s');
mduisnackbar({message:commentsuccess,position:'right-bottom'});
mduisnackbar({message:commentsuccess,position:'right-bottom',timeout:2000});
}
}
});
Expand Down
2 changes: 1 addition & 1 deletion post.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
<form class="mdui-center" id="password-form">
<div class="mdui-valign mdui-center" style="width:100%;max-width:500px;">
<div class="mdui-textfield" style="display:inline-block;width:100%;margin-right:8px;">
<input class="mdui-textfield-input" type="text" name="protectPassword" placeholder="请输入密码访问" />
<input class="mdui-textfield-input" type="password" name="protectPassword" placeholder="请输入密码访问" />
<?php if ($this->fields->passwordhint){ ?><div class="mdui-textfield-helper">提示:<?php echo $this->fields->passwordhint; ?></div><?php } ?>
</div>
<input type="hidden" name="protectCID" value="<?php $this->cid(); ?>" />
Expand Down

0 comments on commit 182c53d

Please sign in to comment.