Procházet zdrojové kódy

6.3特征

tags/6.3.0
叙述、别离 před 1 rokem
rodič
revize
2e275a9a71
17 změnil soubory, kde provedl 34 přidání a 34 odebrání
  1. +2
    -2
      src/admin/catalog_add.php
  2. +1
    -1
      src/admin/config.php
  3. +1
    -1
      src/admin/dialog/config.php
  4. +3
    -3
      src/admin/log_edit.php
  5. +2
    -2
      src/admin/module_make.php
  6. +1
    -1
      src/admin/sys_info_mark.php
  7. +1
    -1
      src/admin/templets/content_batch_up.htm
  8. +1
    -1
      src/admin/templets/sys_safetest.htm
  9. +1
    -1
      src/apps/advancedsearch.php
  10. +2
    -2
      src/apps/jump.php
  11. +1
    -1
      src/apps/search.php
  12. +2
    -2
      src/system/memberlogin.class.php
  13. +1
    -1
      src/user/config.php
  14. +3
    -3
      src/user/edit_baseinfo.php
  15. +8
    -8
      src/user/index_do.php
  16. +3
    -3
      src/user/reg_new.php
  17. +1
    -1
      src/user/resetpassword.php

+ 2
- 2
src/admin/catalog_add.php Zobrazit soubor

@@ -169,13 +169,13 @@ if ($dopost == 'quick') {
$true_typedir = str_replace("{cmspath}", "", $typedir);
$true_typedir = preg_replace("#\/{1,}#", "/", $true_typedir);
if (!CreateDir($true_typedir)) {
ShowMsg("创建目录{$true_typedir}失败,请检查您的路径是否存在问题", "-1");
ShowMsg("创建目录{$true_typedir}失败,请检查路径是否存在问题", "-1");
exit();
}
}
$in_query = "INSERT INTO `#@__arctype` (reid,topid,sortrank,typename,cnoverview,enname,enoverview,bigpic,litimg,typedir,isdefault,defaultname,issend,channeltype,tempindex,templist,temparticle,modname,namerule,namerule2,ispart,corank,description,keywords,seotitle,moresite,siteurl,sitepath,ishidden,`cross`,`crossid`,`content`,`smalltypes`,`apienabled`,`apikey`) VALUES ('$reid','$topid','$sortrank','$typename','$cnoverview','$enname','$enoverview','$bigpic','$litimg','$typedir','$isdefault','$defaultname','$issend','$channeltype','$tempindex','$templist','$temparticle','default','$namerule','$namerule2','$ispart','$corank','$description','$keywords','$seotitle','$moresite','$siteurl','$sitepath','$ishidden','$cross','$crossid','$content','$smalltypes','$apienabled','$apikey')";
if (!$dsql->ExecuteNoneQuery($in_query)) {
ShowMsg("保存目录数据时失败,请检查您的输入资料是否存在问题", "-1");
ShowMsg("保存目录数据时失败,请检查输入资料是否存在问题", "-1");
exit();
}
UpDateCatCache();


+ 1
- 1
src/admin/config.php Zobrazit soubor

@@ -34,7 +34,7 @@ if (!isset($GLOBALS['csrf_token']) || $GLOBALS['csrf_token'] === null) {
if (strtoupper($_SERVER['REQUEST_METHOD']) !== 'POST') {
PutCookie('dede_csrf_token', $GLOBALS['csrf_token'], 7200, '/');
}
//获得当前脚本名称,如果您的系统被禁用了$_SERVER变量,请自行修改这个选项
//获得当前脚本名称,如果系统被禁用了$_SERVER变量,请自行修改这个选项
$dedeNowurl = $s_scriptName = '';
$isUrlOpen = @ini_get('allow_url_fopen');
$dedeNowurl = GetCurUrl();


+ 1
- 1
src/admin/dialog/config.php Zobrazit soubor

@@ -10,7 +10,7 @@
*/
require_once(dirname(__FILE__)."/../../system/common.inc.php");
require_once(DEDEINC."/userlogin.class.php");
//获得当前脚本名称,如果您的系统被禁用了$_SERVER变量,请自行修改这个选项
//获得当前脚本名称,如果系统被禁用了$_SERVER变量,请自行修改这个选项
$dedeNowurl = '';
$s_scriptName = '';
$isUrlOpen = @ini_get('allow_url_fopen');


+ 3
- 3
src/admin/log_edit.php Zobrazit soubor

@@ -11,7 +11,7 @@
require_once(dirname(__FILE__)."/config.php");
CheckPurview('sys_Log');
if (empty($dopost)) {
ShowMsg("您没指定任何参数", "javascript:;");
ShowMsg("请选择一项记录", "log_list.php");
exit();
}
//清空所有日志
@@ -32,10 +32,10 @@ if ($dopost == "clear") {
}
if ($dquery != "") $dquery = " where ".$dquery;
$dsql->ExecuteNoneQuery("DELETE FROM `#@__log` $dquery");
ShowMsg("成功删除指定日志", $bkurl);
ShowMsg("成功删除指定日志", $bkurl);
exit();
} else {
ShowMsg("无法识别您的请求", "javascript:;");
ShowMsg("系统无法识别请求", "log_list.php");
exit();
}
?>

+ 2
- 2
src/admin/module_make.php Zobrazit soubor

@@ -31,7 +31,7 @@ else if ($action == 'make') {
$devContent = $dhd->GetHtml();
$devInfo = (array)json_decode($devContent);
if (($devInfo['auth_at'] + 60 * 60 * 24 * 365) < time()) {
ShowMsg("您贡献者账号已经过期,登录DedeBIZ官网申请续费", "-1");
ShowMsg("您贡献者账号已经过期,登录DedeBIZ官网申请续费", "-1");
exit();
}
$filelist = str_replace("\r", "\n", trim($filelist));
@@ -188,7 +188,7 @@ else if ($action == 'edit') {
$devContent = $dhd->GetHtml();
$devInfo = (array)json_decode($devContent);
if (($devInfo['auth_at'] + 60 * 60 * 24 * 365) < time()) {
ShowMsg("您贡献者账号已经过期,请登录www.dedebiz.com重新申请", "-1");
ShowMsg("您贡献者账号已经过期,请登录www.dedebiz.com重新申请", "-1");
exit();
}
if (strlen($modulname) > 150) {


+ 1
- 1
src/admin/sys_info_mark.php Zobrazit soubor

@@ -12,7 +12,7 @@ require_once(dirname(__FILE__)."/config.php");
CheckPurview('sys_Edit');
require_once(DEDEINC."/image.func.php");
if ($cfg_photo_support == '') {
echo "您的系统没安装GD库,不允许使用本功能";
echo "未安装GD库,不允许使用该功能";
exit();
}
$ImageWaterConfigFile = DEDEDATA."/mark/inc_photowatermark_config.php";


+ 1
- 1
src/admin/templets/content_batch_up.htm Zobrazit soubor

@@ -40,7 +40,7 @@
</td>
</tr>
<tr>
<td>会员登录id:</td>
<td>会员登录id:</td>
<td>
<input name="userid" type="text" id="userid" class="admin-input-xs">
<span>(网址uid=后面跟的id)</span>


+ 1
- 1
src/admin/templets/sys_safetest.htm Zobrazit soubor

@@ -22,7 +22,7 @@
<div class="alert alert-info mb-0">
<ul>
<li>检测结果:结果仅供参考,请务必查看源码后才删除非法文件</li>
<li>安全建议:1、有条件的会员把data、system、theme修改为不可对外浏览,static、a目录设置为不允许执行脚本,其它目录禁止写入,系统更安全;2、本检测程以开发模式为标准,如果您的网站目录包含其它系统,此检测程序会产生错误判断;3、检测程序会跳过对模板缓存目录的检测,为了安全起见,检测完成后建议清空模板缓存</li>
<li>安全建议:1、有条件的会员把data、system、theme修改为不可对外浏览,static、a目录设置为不允许执行脚本,其它目录禁止写入,系统更安全;2、本检测程以开发模式为标准,如果网站目录包含其它系统,此检测程序会产生错误判断;3、检测程序会跳过对模板缓存目录的检测,为了安全起见,检测完成后建议清空模板缓存</li>
</ul>
</div>
</td>


+ 1
- 1
src/apps/advancedsearch.php Zobrazit soubor

@@ -43,7 +43,7 @@ if (empty($sql)) {
$q = stripslashes($q);
$q = preg_replace("#[\|\"\r\n\t%\*\?\(\)\$;,'%<>]#", " ", trim($q));
if (($cfg_notallowstr != '' && preg_match("#".$cfg_notallowstr."#i", $q)) || ($cfg_replacestr != '' && preg_match("#".$cfg_replacestr."#i", $q))) {
echo "您的信息中存在违规文档,被系统禁止";
echo "信息中存在违规文档,被系统禁止";
exit();
}
$q = addslashes($q);


+ 2
- 2
src/apps/jump.php Zobrazit soubor

@@ -24,7 +24,7 @@ if (preg_match("#^http#", $url)) {
$msg = "<code>$url</code><div class='mt-3'><a href='$url' class='btn btn-success btn-sm'>继续访问</a></div>";
$wecome_info = "页面跳转提示";
$win = new OxWindow();
$win->AddTitle("您将要访问的链接不属于当前站点,请关注您的账号安全。");
$win->AddTitle("您将要访问的链接不属于当前站点,请留意账号安全");
$win->AddMsgItem($msg);
$winform = $win->GetWindow("hand", false);
$win->Display();
@@ -33,7 +33,7 @@ if (preg_match("#^http#", $url)) {
header('Location:'.$url);
}
} else {
ShowMsg("地址错误","javascript:;");
ShowMsg("地址错误", "javascript:;");
exit;
}
?>

+ 1
- 1
src/apps/search.php Zobrazit soubor

@@ -57,7 +57,7 @@ $typeid = intval($typeid);
$keyword = addslashes(cn_substr($keyword,30));
$typeid = intval($typeid);
if ($cfg_notallowstr != '' && preg_match("#".$cfg_notallowstr."#i", $keyword)) {
ShowMsg("您的搜索关键词中存在非法文档,被系统禁止", "-1");
ShowMsg("搜索关键词中存在非法文档,被系统禁止", "-1");
exit();
}
if (($keyword != '' && strlen($keyword) < 2) && empty($typeid)) {


+ 2
- 2
src/system/memberlogin.class.php Zobrazit soubor

@@ -68,10 +68,10 @@ function CheckNotAllow()
ShowMsg("您已经被禁言,请与管理员联系", "-1");
exit();
} else if ($cfg_ml->M_Spacesta == -10) {
ShowMsg("系统开启了邮件审核机制,您的帐号需要审核后才能发信息", "-1");
ShowMsg("系统开启了邮件审核机制,帐号需要审核后才能发信息", "-1");
exit();
} else if ($cfg_ml->M_Spacesta < 0) {
ShowMsg('系统开启了审核机制,您的帐号需要管理员审核后才能发信息', '-1');
ShowMsg('系统开启了审核机制,帐号需要管理员审核后才能发信息', '-1');
exit();
}
}


+ 1
- 1
src/user/config.php Zobrazit soubor

@@ -100,7 +100,7 @@ if (!isset($GLOBALS['csrf_token']) || $GLOBALS['csrf_token'] === null) {
if (strtoupper($_SERVER['REQUEST_METHOD']) !== 'POST') {
PutCookie('dede_csrf_token', $GLOBALS['csrf_token'], 7200, '/');
}
//获得当前脚本名称,如果您的系统被禁用了$_SERVER变量,请自行修改这个选项
//获得当前脚本名称,如果系统被禁用了$_SERVER变量,请自行修改这个选项
$dedeNowurl = $s_scriptName = '';
$dedeNowurl = GetCurUrl();
$dedeNowurls = explode('?', $dedeNowurl);


+ 3
- 3
src/user/edit_baseinfo.php Zobrazit soubor

@@ -60,7 +60,7 @@ if ($dopost == 'save') {
//修改安全问题或邮箱
if ($email != $row['email'] || ($newsafequestion != 0 && $newsafeanswer != '')) {
if ($row['safequestion'] != 0 && ($row['safequestion'] != $safequestion || $row['safeanswer'] != $safeanswer)) {
ShowMsg('您的旧安全问题及答案不正确,不能修改邮箱或安全问题', 'edit_baseinfo.php');
ShowMsg('旧安全问题及答案不正确,不能修改邮箱或安全问题', 'edit_baseinfo.php');
exit();
}
//修改邮箱
@@ -77,7 +77,7 @@ if ($dopost == 'save') {
//修改安全问题
if ($newsafequestion != 0 && $newsafeanswer != '') {
if (strlen($newsafeanswer) > 30) {
ShowMsg('您的新安全问题的答案太长了,请保持在30字节以内', 'edit_baseinfo.php');
ShowMsg('新安全问题的答案太长了,请保持在30字节以内', 'edit_baseinfo.php');
exit();
} else {
$newsafequestion = HtmlReplace($newsafequestion, 1);
@@ -109,7 +109,7 @@ if ($dopost == 'save') {
}
//清除会员缓存
$cfg_ml->DelCache($cfg_ml->M_ID);
ShowMsg('成功更新您的基本资料', 'edit_baseinfo.php');
ShowMsg('成功更新账号基本资料', 'edit_baseinfo.php');
exit();
}
include(DEDEMEMBER."/templets/edit_baseinfo.htm");

+ 8
- 8
src/user/index_do.php Zobrazit soubor

@@ -13,11 +13,11 @@ if (empty($dopost)) $dopost = '';
if (empty($fmdo)) $fmdo = '';
if ($fmdo == 'sendMail') {
if (!CheckEmail($cfg_ml->fields['email'])) {
ShowMsg('您的邮箱格式有错误', 'index.php');
ShowMsg('邮箱格式有错误', 'index.php');
exit();
}
if ($cfg_ml->fields['spacesta'] != -10) {
ShowMsg('您的帐号不在邮件验证状态,本操作无效', 'index.php');
ShowMsg('帐号不在邮件验证状态,本操作无效', 'index.php');
exit();
}
$userhash = md5($cfg_cookie_encode.'--'.$cfg_ml->fields['mid'].'--'.$cfg_ml->fields['email']);
@@ -44,22 +44,22 @@ if ($fmdo == 'sendMail') {
@mail($cfg_ml->fields['email'], $mailtitle, $mailbody, $headers);
}
}
ShowMsg('成功发送邮件,请稍后登录您的邮箱进行接收', 'index.php');
ShowMsg('成功发送邮件,请稍后登录邮箱进行接收', 'index.php');
exit();
} else if ($fmdo == 'checkMail') {
$mid = intval($mid);
if (empty($mid)) {
ShowMsg('您的效验串不合法', 'index.php');
ShowMsg('效验串不合法', 'index.php');
exit();
}
$row = $dsql->GetOne("SELECT * FROM `#@__member` WHERE mid='{$mid}' ");
$needUserhash = md5($cfg_cookie_encode.'--'.$mid.'--'.$row['email']);
if ($needUserhash != $userhash) {
ShowMsg('您的效验串不合法', 'index.php');
ShowMsg('效验串不合法', 'index.php');
exit();
}
if ($row['spacesta'] != -10) {
ShowMsg('操作无效,您的帐号不在邮件验证状态', 'index.php');
ShowMsg('操作无效,帐号不在邮件验证状态', 'index.php');
exit();
}
$dsql->ExecuteNoneQuery("UPDATE `#@__member` SET spacesta=0 WHERE mid='{$mid}' ");
@@ -175,11 +175,11 @@ if ($fmdo == 'sendMail') {
$rs = $cfg_ml->CheckUser($userid, $pwd);
if ($rs == 0) {
ResetVdValue();
ShowMsg('您的账号错误', 'index.php');
ShowMsg('账号输入错误', 'index.php');
exit();
} else if ($rs == -1) {
ResetVdValue();
ShowMsg('您的密码错误', 'index.php');
ShowMsg('密码输入错误', 'index.php');
exit();
} else if ($rs == -2) {
ResetVdValue();


+ 3
- 3
src/user/reg_new.php Zobrazit soubor

@@ -40,11 +40,11 @@ if ($step == 1) {
exit();
}
if (strlen($userid) > 20 || strlen($uname) > 36) {
ShowMsg('您的账号或账号过长,不允许注册', '-1');
ShowMsg('账号或账号过长,不允许注册', '-1');
exit();
}
if (strlen($userid) < $cfg_mb_idmin || strlen($pwd) < $cfg_mb_pwdmin) {
ShowMsg("您的账号或密码过短,不允许注册", "-1");
ShowMsg("账号或密码过短,不允许注册", "-1");
exit();
}
if (preg_match("#[^0-9a-zA-Z_@!\.-]#", $userid)) {
@@ -63,7 +63,7 @@ if ($step == 1) {
ShowMsg("您指定的账号{$userid}已存在,请使用别的账号", "-1");
exit();
}
//会员默认金币
//会员默认金币
$dfscores = 0;
$dfmoney = 0;
$dfrank = $dsql->GetOne("SELECT `money`,scores FROM `#@__arcrank` WHERE `rank`='10' ");


+ 1
- 1
src/user/resetpassword.php Zobrazit soubor

@@ -65,7 +65,7 @@ if ($dopost == "") {
sn($mid, $row['userid'], $row['email'], 'N');
exit();
} else {
ShowMsg("您的安全问题或答案回答错误", "login.php");
ShowMsg("安全问题或答案回答错误", "login.php");
exit();
}
} else if ($dopost == "getpasswd") {


Načítá se…
Zrušit
Uložit