| @@ -50,17 +50,15 @@ Sockets:支持接入DedeBIZ商业组件模块 | |||
| ``` | |||
| / | |||
| ..../install 安装程序目录,安装完后可删除[安装时必须有可写入权限] | |||
| ..../dede 默认后台管理目录(可任意改名) | |||
| ..../include 类库文件目录[建议关闭对外访问权限] | |||
| ..../plus 插件扩展程序目录 | |||
| ..../member 会员目录 | |||
| ..../static 静态资源存放目录 | |||
| ..../uploads 默认上传目录[必须可写入] | |||
| ..../a 默认HTML文件存放目录[必须可写入] | |||
| ..../templets 系统默认内核模板目录 | |||
| ..../admin 默认后台管理目录[可任意改名] | |||
| ..../apps 插件扩展程序目录 | |||
| ..../data 系统缓存或其它可写入数据存放目录[必须可写入] | |||
| ..../special 专题目录[生成一次专题后可以删除special/index.php,必须可写入] | |||
| ..../install 安装程序目录,安装完后可删除[安装时必须有可写入权限] | |||
| ..../static 静态资源存放目录[必须可写入] | |||
| ..../system 类库文件目录[建议关闭对外访问权限] | |||
| ..../theme 系统默认内核模板目录 | |||
| ..../user 会员目录 | |||
| ``` | |||
| 5.PHP环境容易碰到的不兼容性问题 | |||
| @@ -78,7 +78,7 @@ make_hash(); | |||
| $msg = " | |||
| <link href='css/base.css' rel='stylesheet' type='text/css' /> | |||
| <script language='javascript' src='js/main.js'></script> | |||
| <script language='javascript' src='../static/js/dedeajax2.js'></script> | |||
| <script language='javascript' src='../static/js/webajax.js'></script> | |||
| <script language='javascript'> | |||
| function DoRand(jobname) | |||
| { | |||
| @@ -1 +1 @@ | |||
| *{padding:0;margin:0;box-sizing:border-box}a{text-decoration:none}html,body{width:100%;height:100%}body{height:100%;font-size:12px;overflow:hidden;z-index:1}body.hidemenu{background:none}ul{list-style:none}form{margin:0;padding:0}.head{width:100%;height:76px;overflow:hidden;z-index:8;position:relative}.top{height:46px;width:100%;background-image:linear-gradient(135deg,#008E38 0%,#639709 50%);overflow:hidden;clear:both}.top .top_logo{float:left;margin-left:30px;height:46px;line-height:46px}.top .top_logo a{font-size:18px;font-weight:600;color:#fff}.top .top_version{display:inline-block;margin-top:12px;margin-left:10px;color:#fff}.top .top_link{float:right;margin-right:30px}.top .top_link ul{float:left;line-height:46px;overflow:hidden}.top .top_link ul li.welcome img{margin-top:-2px;margin-right:10px;width:30px;height:30px;vertical-align:middle;border-radius:50%}.top .top_link ul li{float:left;color:#fff}.top .top_link ul li a{color:#fff;padding-left:20px}.top .top_link ul li a:hover{color:#ccc}.top .top_link .quick{padding:3px 0px 0px 0px;float:left}.top .top_link .quick a{display:block;color:#C60;float:left;line-height:21px;height:21px;overflow:hidden}.topnav{width:100%;height:30px;line-height:30px;background:#393d49;overflow:hidden;clear:both}.topnav .menuact{width:168px;float:left;padding-left:30px;overflow:hidden}.topnav .menuact a{overflow:hidden;color:#eee;padding-right:10px}.topnav .menuact a:hover{color:#fff}.nav{float:left;padding-left:2px;line-height:26px;color:#999}.nav ul li{float:left;display:block;margin-left:4px}.nav ul li a{padding:0 10px 0px 10px;color:#FFCC00}.nav ul li a:hover{color:#fff}.nav ul li a.thisclass,.nav ul li a.thisclass:hover{color:#4E8100;display:block;font-weight:bold;background:#fff;line-height:23px;border-top:2px solid #FFDE59;margin-top:4px;padding:0 10px 0px 10px}.sysmsg{padding-right:30px;float:right;width:500px;color:#999;overflow:hidden}.scroll{float:right;overflow:hidden}.scroll ul li,.sysmsg ul li a{color:#bbb}.scroll ul li a:hover{text-decoration:underline}.scroll a{padding-left:10px;color:#fff}body.showmenu .left{display:block}body.hidemenu .left{display:none}body.showmenu .right{left:220px}body.hidemenu .right{left:0}.left{position:absolute;top:76px;width:220px;left:0;bottom:0;z-index:7}.menu{height:100%}.top_link{font-size:12px}.menu iframe{height:100%;width:99.99%;z-index:20}.right{position:absolute;right:0;top:76px;bottom:0;z-index:7}.main{height:100%}.main iframe{height:100%;width:99.99%;z-index:20}.qucikmenu{position:absolute;right:10px;top:32px;z-index:9;display:none}.qucikmenu ul{width:110px;list-style:none;border:1px solid #E7E7E7;background:#fff}.qucikmenu ul li{display:block;text-align:left}.qucikmenu ul li a{height:30px;line-height:30px;display:block;color:#666;padding-left:10px;padding-right:10px}.qucikmenu ul li a:hover{background:#F7F7F7}.pagemask{width:100%;height:100%;background:#424b51;position:absolute;z-index:100;filter:alpha(opacity=70);-moz-opacity:.7;opacity:.7;display:none}.iframemask{position:absolute;z-index:80;top:0;left:0;background:#fff;border:none;filter:alpha(opacity=0);-moz-opacity:0;opacity:0;height:100%;width:100%;display:none}.allmenu{margin-left:-400px;padding:10px;display:none;width:800px;position:absolute;top:76px;left:50%;z-index:999;background:#fff;border-radius:.2rem}.allmenu .allmenu-box{margin:0 auto;text-align:left;overflow:hidden;padding-left:2px}.maptop{float:left;width:130px;overflow:hidden;padding-right:6px;padding-left:6px;margin-left:-1px}.maptop dt.bigitem{padding:5px 10px;line-height:18px;color:#fff;background:#424b51}.mapitem dt{line-height:30px;font-weight:bold;text-indent:10px;background:#EFF1F1}.mapitem ul{margin-top:10px;margin-bottom:10px}.mapitem ul li{text-indent:20px;line-height:24px;background:url(../images/arrr.gif)0 8px no-repeat}.allmenu a{color:#5C604F}.allmenu a:hover{color:#F63}#login .theme{clear:both;padding:10px;width:70%;margin-top:20px}#login .theme li{margin-bottom:15px;margin-top:5px;overflow:hidden}#login .theme span{display:inline-block;float:left;width:150px;height:22px;line-height:22px;color:#424b51;text-align:right}input[type="text"],input[type="password"]{padding:2px 4px;width:140px;height:18px;line-height:18px;border-width:1px;border-style:solid;border-color:#fff;background:#fff;vertical-align:middle}input[type="text"]:focus,input[type="password"]:focus{box-shadow:none;outline:none}* html input.text{width:220px;border:1px solid #a7a6aa;background:#fff url(../images/input.gif)0 0 no-repeat;margin-top:-1px;margin-right:5px;margin-bottom:0;margin-left:2px;padding:3px;line-height:12px}* html input.radio{margin:-1px 0 0 -2px}.allsearch{float:left;margin-top:6px!important;font-size:12px;border:1px solid #fff;border-radius:.2rem}.np{margin-left:10px;width:40px;height:18px;font-size:12px;color:#fff;background:#57960f;border-radius:.2rem;border:none;cursor:pointer} | |||
| *{padding:0;margin:0;letter-spacing:.4px;box-sizing:border-box}body{line-height:1.5;font:12px Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif;color:#424b51;background:#fff;overflow:hidden}body.hidemenu{background:none}a{text-decoration:none}ul{list-style:none}.head{width:100%;height:76px;overflow:hidden;z-index:8;position:relative}.top{height:46px;width:100%;background-image:linear-gradient(135deg,#008E38 0%,#639709 50%);overflow:hidden;clear:both}.top .top_logo{float:left;margin-left:30px;height:46px;line-height:46px}.top .top_logo a{font-size:18px;font-weight:600;color:#fff}.top .top_version{display:inline-block;margin-top:12px;margin-left:10px;color:#fff}.top .top_link{float:right;margin-right:30px}.top .top_link ul{float:left;line-height:46px;overflow:hidden}.top .top_link ul li.welcome img{margin-top:-2px;margin-right:10px;width:30px;height:30px;vertical-align:middle;border-radius:50%}.top .top_link ul li{float:left;color:#fff}.top .top_link ul li a{color:#fff;padding-left:20px}.top .top_link ul li a:hover{color:#ccc}.top .top_link .quick{padding:3px 0px 0px 0px;float:left}.top .top_link .quick a{display:block;color:#C60;float:left;line-height:21px;height:21px;overflow:hidden}.topnav{width:100%;height:30px;line-height:30px;background:#393d49;overflow:hidden;clear:both}.topnav .menuact{width:168px;float:left;padding-left:30px;overflow:hidden}.topnav .menuact a{overflow:hidden;color:#eee;padding-right:10px}.topnav .menuact a:hover{color:#fff}.nav{float:left;padding-left:2px;line-height:26px;color:#999}.nav ul li{float:left;display:block;margin-left:4px}.nav ul li a{padding:0 10px 0px 10px;color:#FFCC00}.nav ul li a:hover{color:#fff}.nav ul li a.thisclass,.nav ul li a.thisclass:hover{color:#4E8100;display:block;font-weight:bold;background:#fff;line-height:23px;border-top:2px solid #FFDE59;margin-top:4px;padding:0 10px 0px 10px}.sysmsg{padding-right:30px;float:right;width:500px;color:#999;overflow:hidden}.scroll{float:right;overflow:hidden}.scroll ul li,.sysmsg ul li a{color:#bbb}.scroll ul li a:hover{text-decoration:underline}.scroll a{padding-left:10px;color:#fff}body.showmenu .left{display:block}body.hidemenu .left{display:none}body.showmenu .right{left:220px}body.hidemenu .right{left:0}.left{position:absolute;top:76px;width:220px;left:0;bottom:0;z-index:7}.menu{height:100%}.menu iframe{height:100%;width:99.99%;z-index:20}.right{position:absolute;right:0;top:76px;bottom:0;z-index:7}.main{height:100%}.main iframe{height:100%;width:99.99%;z-index:20}.qucikmenu{position:absolute;right:10px;top:32px;z-index:9;display:none}.qucikmenu ul{width:110px;list-style:none;border:1px solid #E7E7E7;background:#fff}.qucikmenu ul li{display:block;text-align:left}.qucikmenu ul li a{display:block;padding:0 10px;height:30px;line-height:30px;color:#666}.qucikmenu ul li a:hover{background:#f6f6f6}.pagemask{position:absolute;display:none;width:100%;height:100%;background:#424b51;opacity:.7;z-index:100}.iframemask{position:absolute;display:none;z-index:80;top:0;left:0;width:100%;height:100%;background:#fff;border:none;opacity:0}.allmenu{position:absolute;display:none;margin-left:-400px;padding:10px;width:800px;top:76px;left:50%;background:#fff;border-radius:.2rem;z-index:999}.allmenu .allmenu-box{margin:0 auto;text-align:left;overflow:hidden;padding-left:2px}.maptop{margin-left:-1px;padding-right:6px;padding-left:6px;float:left;width:130px;overflow:hidden}.maptop dt.bigitem{padding:6px 10px;line-height:18px;color:#fff;background:#424b51}.mapitem dt{line-height:30px;text-indent:10px;background:#EFF1F1}.mapitem ul{margin-top:10px;margin-bottom:10px}.mapitem ul li{text-indent:20px;line-height:24px;background:url(../images/arrr.gif)0 8px no-repeat}.allmenu a{color:#5C604F}.allmenu a:hover{color:#F63}#login .theme{padding:10px;margin-top:20px;width:70%;clear:both}#login .theme li{margin-bottom:15px;margin-top:5px;overflow:hidden}#login .theme span{display:inline-block;float:left;width:150px;height:22px;line-height:22px;color:#424b51;text-align:right}input[type="text"],input[type="password"]{padding:2px 4px;width:140px;height:18px;line-height:18px;font-size:12px;border-width:1px;border-style:solid;border-color:#fff;background:#fff;vertical-align:middle}input[type="text"]:focus,input[type="password"]:focus{box-shadow:none;outline:none}.allsearch{float:left;margin-top:6px;border:1px solid #fff;border-radius:.2rem}.np{margin-top:6px;margin-left:10px;width:40px;height:18px;font-size:12px;color:#fff;background:#57960f;border-radius:.2rem;border:0;cursor:pointer} | |||
| @@ -1 +1 @@ | |||
| .title{color:#666600;font-weight:bold}.title span{padding-left:3px}#addTab{position:absolute;left:460px;top:260px;width:360px;height:200px;z-index:2;background:#fff;border:1px solid #ccc;padding:0px;display:none;border-radius:.2rem}#editTab{position:absolute;left:460px;top:260px;width:360px;height:300px;z-index:1;background:#fff;border:1px solid #ccc;padding:0px;display:none;border-radius:.2rem}.txt{float:left}.updatedvt{width:98%;border-bottom:1px dashed #dcdcdc}.upinfotitle{border-bottom:1px solid #ccc;color:#dc3545;font-weight:bold}.verline{border-bottom:1px dashed #ccc}.itemTable{background:#CBD8AC}#loaddiv{top:0;left:0;background:#ccc;filter:Alpha(opacity=70);-moz-opacity:0.7;position:absolute;z-index:10000;width:100%;height:100%}#mainmsg{padding-right:8px}.rightside{width:49%;float:left;margin-right:1%;height:670px}.column{width:49%;float:left;margin-right:0.5%}.placeholder{width:98%;margin-left:1%;background:#f0f0f0;border:1px dashed #ddd}.dbox{border:1px solid #DEEAB6;width:98%;margin-left:1%;margin-top:8px}.dbox dt{height:28px;line-height:28px;font-weight:bold;color:#4D6C2F;cursor:move}.dbox dt .l{float:left;padding-left:8px}.dbox dt .r{float:right;padding-right:8px}.dbox dt.lside{border-bottom:1px solid #CFD7C4;background:rgb(239,248,229)}.dbox dt.rside{border-bottom:1px solid #DEEAB6;background:url(../images/wbg.gif)repeat-x}.dbox dd{padding:0px}.dbox dd.intable{padding-top:0}#updatetest{padding:6px;padding-left:110px;background:url(../images/ico_spider.gif)no-repeat scroll 10px 15px transparent}#quickmenu{width:100%;height:46px;overflow:hidden}#quickmenu .icoitem{float:left;height:24px;line-height:24px;margin-top:10px;padding-left:30px;overflow:hidden}.dboxtable td.nline{border-bottom:1px dashed #CFD7C4;height:26px}.dboxtable1 ul li{float:left;border-bottom:1px dashed #CFD7C4;height:26px;line-height:26px;display:inline;width:48%;text-align:center}.biz p{padding:0 15px}.biz img{float:right;margin:40px 15px 0 15px} | |||
| .title{color:#666600}.title span{padding-left:6px}#addTab{position:absolute;left:460px;top:260px;min-width:360px;height:200px;z-index:2;background:#fff;border:1px solid #ccc;padding:0px;display:none;border-radius:.2rem}#editTab{position:absolute;left:460px;top:260px;min-width:360px;height:300px;z-index:1;background:#fff;border:1px solid #ccc;padding:0px;display:none;border-radius:.2rem}.txt{float:left}.updatedvt{width:98%;border-bottom:1px dashed #dcdcdc}.upinfotitle{border-bottom:1px solid #ccc;color:#dc3545;font-weight:bold}.verline{border-bottom:1px dashed #ccc}.itemTable{background:#CBD8AC}#loaddiv{top:0;left:0;background:#ccc;filter:Alpha(opacity=70);-moz-opacity:0.7;position:absolute;z-index:10000;width:100%;height:100%}#mainmsg{padding-right:8px}.rightside{width:49%;float:left;margin-right:1%;height:670px}.column{width:49%;float:left;margin-right:0.5%}.placeholder{width:98%;margin-left:1%;background:#f0f0f0;border:1px dashed #ddd}.dbox{border:1px solid #DEEAB6;width:98%;margin-left:1%;margin-top:8px}.dbox dt{height:28px;line-height:28px;font-weight:bold;color:#4D6C2F;cursor:move}.dbox dt .l{float:left;padding-left:8px}.dbox dt .r{float:right;padding-right:8px}.dbox dt.lside{border-bottom:1px solid #CFD7C4;background:rgb(239,248,229)}.dbox dt.rside{border-bottom:1px solid #DEEAB6;background:url(../images/wbg.gif)repeat-x}.dbox dd{padding:0px}.dbox dd.intable{padding-top:0}#updatetest{padding:6px;padding-left:110px;background:url(../images/ico_spider.gif)no-repeat scroll 10px 15px transparent}#quickmenu{width:100%;height:46px;overflow:hidden}#quickmenu .icoitem{float:left;height:24px;line-height:24px;margin-top:10px;padding-left:30px;overflow:hidden}.dboxtable td.nline{height:26px;border-bottom:1px dashed #CFD7C4}.dboxtable1 ul li{float:left;display:inline;width:48%;height:26px;line-height:26px;border-bottom:1px dashed #CFD7C4;text-align:center}.biz p{padding:0 15px}.biz img{float:right;margin:40px 15px 0 15px} | |||
| @@ -1 +1 @@ | |||
| div{padding:0px;margin:0px;}body{scrollbar-base-color:#bae87c;scrollbar-arrow-color:#FFFFFF;scrollbar-shadow-color:#c1ea8b;padding:0px;margin:auto;text-align:center;background-color:#9ad075;}dl.bitem{width:148px;margin:0px 0px 5px 4px;}dl.bitem dt{background:url(../images/menubg.gif);height:26px;line-height:26px;text-align:center;cursor:pointer;}dl.bitem dd{padding:3px 3px 3px 3px;background-color:#fff;}.fllct{float:left;width:90px;}.flrct{padding-top:3px;float:left;}div.items{line-height:22px;background:url(../images/arr4.gif) no-repeat 10px 9px;}span.items{padding:10px 0px 10px 22px;background:url(../images/arr4.gif) no-repeat 10px 12px;}ul{padding-top:3px;}li{height:22px;}.sitemu li{padding:0px 0px 0px 22px;line-height:24px;background:url(../images/arr4.gif) no-repeat 10px 9px;} | |||
| div{margin:0px;padding:0px}body{margin:auto;padding:0px;background:#9ad075;text-align:center}dl.bitem{width:148px;margin:0px 0px 6px 6px}dl.bitem dt{background:url(../images/menubg.gif);height:26px;line-height:26px;text-align:center;cursor:pointer}dl.bitem dd{padding:6px;background-color:#fff}.fllct{float:left;width:90px}.flrct{padding-top:2px;float:left}div.items{line-height:22px;background:url(../images/arr4.gif) no-repeat 10px 9px}span.items{padding:10px 0px 10px 22px;background:url(../images/arr4.gif) no-repeat 10px 12px}ul{padding-top:2px}li{height:22px}.sitemu li{padding:0px 0px 0px 22px;line-height:24px;background:url(../images/arr4.gif) no-repeat 10px 9px} | |||
| @@ -1,6 +1,6 @@ | |||
| <?php | |||
| /** | |||
| * 图片选择框 | |||
| * 图片选择 | |||
| * | |||
| * @version $Id: select_images.php 1 9:43 2010年7月8日Z tianya $ | |||
| * @package DedeBIZ.Dialog | |||
| @@ -49,18 +49,17 @@ if (!empty($noeditor)) { | |||
| <html> | |||
| <head> | |||
| <meta charset="<?php echo $cfg_soft_lang; ?>"> | |||
| <title>图片浏览器</title> | |||
| <title>选择图片</title> | |||
| <link rel="stylesheet" href="../../static/css/bootstrap.min.css"> | |||
| <link rel="stylesheet" href="../../static/font-awesome/css/font-awesome.min.css"> | |||
| <link rel="stylesheet" href="../css/base.css"> | |||
| <style> | |||
| html{background:#f2f2f2} | |||
| body{margin:0;line-height:1.5;font:12px Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif} | |||
| a{text-decoration:none!important} | |||
| table{background:#fff} | |||
| a{text-decoration:none!important} | |||
| .bg{margin:10px;border-radius:.2rem;box-shadow:0 1px 2px 0 rgba(0,0,0,.05)} | |||
| .napisdiv{left:10;top:10;width:150px;height:100px;position:absolute;z-index:3;display:none} | |||
| .linerow{border-bottom:1px solid #eee!important} | |||
| .napisdiv{left:40;top:10;width:150px;height:100px;position:absolute;z-index:3;display:none} | |||
| </style> | |||
| <script> | |||
| function nullLink() { | |||
| @@ -134,7 +133,7 @@ table{background:#fff} | |||
| <input type="hidden" name="imgstick" value="<?php echo $imgstick ?>"> | |||
| <input type="hidden" name="CKEditorFuncNum" value="<?php echo isset($CKEditorFuncNum) ? $CKEditorFuncNum : 1; ?>"> | |||
| <input type="hidden" name="job" value="upload"> | |||
| 上传:<input type="file" name="imgfile" style="width:160px;border:none"> | |||
| 上传:<input type="file" name="imgfile" style="width:260px;border:none"> | |||
| <label><input type="checkbox" name="needwatermark" value="1" class="np" <?php if ($photo_markup == '1') echo "checked"; ?> /> 水印 </label> | |||
| <label><input type="checkbox" name="resize" value="1" class="np"> 缩小 </label> | |||
| 宽:<input type="text" name="iwidth" value="<?php echo $cfg_ddimg_width ?>" style="width:46px"> | |||
| @@ -144,9 +143,9 @@ table{background:#fff} | |||
| </td> | |||
| </tr> | |||
| <tr> | |||
| <td width="10%" class="linerow">预览</td> | |||
| <td width="8%" class="linerow">预览</td> | |||
| <td width="40%" class="linerow">选择图片</td> | |||
| <td width="20%" class="linerow">文件大小</td> | |||
| <td width="22%" class="linerow">文件大小</td> | |||
| <td width="30%" class="linerow">修改时间</td> | |||
| </tr> | |||
| <tr> | |||
| @@ -1,6 +1,6 @@ | |||
| <?php | |||
| /** | |||
| * 多媒体选择框 | |||
| * 多媒体选择 | |||
| * | |||
| * @version $Id: select_media.php 1 9:43 2010年7月8日Z tianya $ | |||
| * @package DedeBIZ.Dialog | |||
| @@ -43,15 +43,14 @@ if (!empty($noeditor)) { | |||
| <html> | |||
| <head> | |||
| <meta http-equiv='Content-Type' content='text/html; charset=<?php echo $cfg_soft_lang; ?>'> | |||
| <title>媒体文件管理器</title> | |||
| <title>选择多媒体</title> | |||
| <link rel="stylesheet" href="../../static/css/bootstrap.min.css"> | |||
| <link rel="stylesheet" href="../../static/font-awesome/css/font-awesome.min.css"> | |||
| <link rel="stylesheet" href="../css/base.css"> | |||
| <style> | |||
| html{background:#f2f2f2} | |||
| body{margin:0;line-height:1.5;font:12px Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif} | |||
| a{text-decoration:none!important} | |||
| table{background:#fff} | |||
| a{text-decoration:none!important} | |||
| .bg{margin:10px;border-radius:.2rem;box-shadow:0 1px 2px 0 rgba(0,0,0,.05)} | |||
| .linerow{border-bottom:1px solid #eee!important} | |||
| </style> | |||
| @@ -80,7 +79,7 @@ table{background:#fff} | |||
| <input type="hidden" name="f" value="<?php echo $f ?>"> | |||
| <input type="hidden" name="job" value="upload"> | |||
| <input type="hidden" name="CKEditorFuncNum" value="<?php echo isset($CKEditorFuncNum) ? $CKEditorFuncNum : 1; ?>"> | |||
| 上传:<input type="file" name="uploadfile" style="width:160px;border:none"> | |||
| 上传:<input type="file" name="uploadfile" style="width:360px;border:none"> | |||
| <button type="submit" name="sb1" class="btn btn-success btn-sm">确定</button> | |||
| </form> | |||
| </td> | |||
| @@ -74,19 +74,11 @@ button+button{margin-left:10px} | |||
| el.setAttribute('data-num',i); | |||
| }); | |||
| } | |||
| function isFileImage(file) { | |||
| return file && file['type'].split('/')[0] === 'image'; | |||
| } | |||
| function addList(files){ | |||
| var files_sum = files.length; | |||
| var vDom = document.createDocumentFragment(); | |||
| for(let i=0;i<files_sum;i++){ | |||
| let file = files[i]; | |||
| if (!isFileImage(file)) { | |||
| alert("选择非图片文件无法上传") | |||
| return; | |||
| } | |||
| console.log(file); | |||
| let blobUrl = window.URL.createObjectURL(file) | |||
| axupimgs.res.push({file:file,blobUrl:blobUrl,url:''}); | |||
| let li = document.createElement('li'); | |||
| @@ -1,6 +1,6 @@ | |||
| <?php | |||
| /** | |||
| * 软件选择框 | |||
| * 软件选择 | |||
| * | |||
| * @version $Id: select_soft.php 1 9:43 2010年7月8日Z tianya $ | |||
| * @package DedeBIZ.Dialog | |||
| @@ -42,15 +42,14 @@ if (!empty($noeditor)) { | |||
| <html> | |||
| <head> | |||
| <meta charset="<?php echo $cfg_soft_lang; ?>"> | |||
| <title>软件管理器</title> | |||
| <title>选择软件</title> | |||
| <link rel="stylesheet" href="../../static/css/bootstrap.min.css"> | |||
| <link rel="stylesheet" href="../../static/font-awesome/css/font-awesome.min.css"> | |||
| <link rel="stylesheet" href="../css/base.css"> | |||
| <style> | |||
| html{background:#f2f2f2} | |||
| body{margin:0;line-height:1.5;font:12px Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif} | |||
| a{text-decoration:none!important} | |||
| table{background:#fff} | |||
| a{text-decoration:none!important} | |||
| .bg{margin:10px;border-radius:.2rem;box-shadow:0 1px 2px 0 rgba(0,0,0,.05)} | |||
| .linerow{border-bottom:1px solid #eee!important} | |||
| </style> | |||
| @@ -1,6 +1,6 @@ | |||
| <?php | |||
| /** | |||
| * 模板选择框 | |||
| * 模板选择 | |||
| * | |||
| * @version $Id: select_templets.php 1 9:43 2010年7月8日Z tianya $ | |||
| * @package DedeBIZ.Dialog | |||
| @@ -34,15 +34,14 @@ if (empty($comeback)) { | |||
| <html> | |||
| <head> | |||
| <meta charset="<?php echo $cfg_soft_lang; ?>"> | |||
| <title>模板管理器</title> | |||
| <title>选择模板</title> | |||
| <link rel="stylesheet" href="../../static/css/bootstrap.min.css"> | |||
| <link rel="stylesheet" href="../../static/font-awesome/css/font-awesome.min.css"> | |||
| <link rel="stylesheet" href="../css/base.css"> | |||
| <style> | |||
| html{background:#f2f2f2} | |||
| body{margin:0;line-height:1.5;font:12px Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif} | |||
| a{text-decoration:none!important} | |||
| table{background:#fff} | |||
| a{text-decoration:none!important} | |||
| .bg{margin:10px;border-radius:.2rem;box-shadow:0 1px 2px 0 rgba(0,0,0,.05)} | |||
| .linerow{border-bottom:1px solid #eee!important} | |||
| </style> | |||
| @@ -20,5 +20,5 @@ $defaultIcoFile = DEDEDATA.'/admin/quickmenu.txt'; | |||
| $myIcoFile = DEDEDATA.'/admin/quickmenu-'.$cuserLogin->getUserID().'.txt'; | |||
| if (!file_exists($myIcoFile)) $myIcoFile = $defaultIcoFile; | |||
| require(DEDEADMIN.'/inc/inc_menu_map.php'); | |||
| include(DEDEADMIN.'/templets/index2.htm'); | |||
| include(DEDEADMIN.'/templets/index.htm'); | |||
| exit(); | |||
| @@ -12,4 +12,4 @@ require(dirname(__FILE__).'/config.php'); | |||
| require(DEDEADMIN.'/inc/inc_menu.php'); | |||
| require(DEDEADMIN.'/inc/inc_menu_func.php'); | |||
| $openitem = (empty($openitem) ? 1 : $openitem); | |||
| include DedeInclude('templets/index_menu2.htm'); | |||
| include DedeInclude('templets/index_menu.htm'); | |||
| @@ -9,7 +9,7 @@ | |||
| <link href="css/albumupload.css" rel="stylesheet" type="text/css" /> | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script src="../static/js/bootstrap.bundle.js"></script> | |||
| <script type="text/javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script type="text/javascript" src="../static/js/webajax.js"></script> | |||
| <link href="../static/css/daterangepicker.css" rel="stylesheet"> | |||
| <script type="text/javascript" src="../static/js/moment.min.js"></script> | |||
| <script type="text/javascript" src="../static/js/daterangepicker.js"></script> | |||
| @@ -8,7 +8,7 @@ | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| <link href="css/albumupload.css" rel="stylesheet" type="text/css" /> | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script type="text/javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script type="text/javascript" src="../static/js/webajax.js"></script> | |||
| <link href="../static/css/daterangepicker.css" rel="stylesheet"> | |||
| <script type="text/javascript" src="../static/js/moment.min.js"></script> | |||
| <script type="text/javascript" src="../static/js/daterangepicker.js"></script> | |||
| @@ -7,7 +7,7 @@ | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <link href="../static/css/daterangepicker.css" rel="stylesheet"> | |||
| <script type="text/javascript" src="../static/js/moment.min.js"></script> | |||
| <script type="text/javascript" src="../static/js/daterangepicker.js"></script> | |||
| @@ -7,7 +7,7 @@ | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| <script src="../static/js/jquery.js"></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <script src="../static/js/bootstrap.bundle.js"></script> | |||
| <script language="javascript" src="js/main.js"></script> | |||
| <link href="../static/css/daterangepicker.css" rel="stylesheet"> | |||
| @@ -8,7 +8,7 @@ | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script src="../static/js/bootstrap.bundle.js"></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <link href="../static/css/daterangepicker.css" rel="stylesheet"> | |||
| <script type="text/javascript" src="../static/js/moment.min.js"></script> | |||
| <script type="text/javascript" src="../static/js/daterangepicker.js"></script> | |||
| @@ -7,7 +7,7 @@ | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <script type="text/javascript" src="../static/js/moment.min.js"></script> | |||
| <script type="text/javascript" src="../static/js/daterangepicker.js"></script> | |||
| <script language="javascript" src="js/main.js"></script> | |||
| @@ -10,7 +10,7 @@ | |||
| <link rel="stylesheet" href="../static/css/jquery.fileupload.css"> | |||
| <link rel="stylesheet" href="../static/css/cropper.min.css"> | |||
| <script src="../static/js/jquery.js"></script> | |||
| <script src="../static/js/dedeajax2.js"></script> | |||
| <script src="../static/js/webajax.js"></script> | |||
| <script src="../static/js/moment.min.js"></script> | |||
| <script src="../static/js/daterangepicker.js"></script> | |||
| <script src="js/main.js"></script> | |||
| @@ -266,8 +266,8 @@ table{border-collapse:separate} | |||
| <td width="90"> 附加选项:</td> | |||
| <td> | |||
| <label><input name="remote" type="checkbox" class="np" id="remote" value="1" <?php if($cfg_rm_remote=='Y') echo ' checked="1" '; ?>> 下载远程图片和资源 </label> | |||
| <label><input name="dellink" type="checkbox" class="np" id="dellink" value="1" <?php if($cfg_arc_dellink=='Y') echo ' checked="1" '; ?>> 删除非站内链接 </label> | |||
| <a href="javascript:OpenMyWin('article_allowurl_edit.php')">[设置]</a> | |||
| <label><input name="dellink" type="checkbox" class="np" id="dellink" value="1" <?php if($cfg_arc_dellink=='Y') echo ' checked="1" '; ?>> 删除非站内链接</label> | |||
| <a href="javascript:OpenMyWin('article_allowurl_edit.php')" class="btn btn-success btn-sm">设置</a> | |||
| <label><input name="autolitpic" type="checkbox" class="np" id="autolitpic" value="1" <?php if($cfg_arc_autopic=='Y') echo ' checked="1" '; ?>> 提取第一个图片为缩略图 </label> | |||
| <label><input type='checkbox' name='needwatermark' value='1' class='np' <?php if($photo_markup=='1') echo "checked"; ?>> 图片是否加水印</label> | |||
| </td> | |||
| @@ -9,7 +9,7 @@ | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script src="../static/js/bootstrap.bundle.js"></script> | |||
| <script language='javascript' src='js/main.js'></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <script language="javascript"> | |||
| function ShowAddNode() { | |||
| $DE('addNode').style.display = 'block'; | |||
| @@ -10,7 +10,7 @@ | |||
| <link rel="stylesheet" href="../static/css/jquery.fileupload.css"> | |||
| <link rel="stylesheet" href="../static/css/cropper.min.css"> | |||
| <script src="../static/js/jquery.js"></script> | |||
| <script src="../static/js/dedeajax2.js"></script> | |||
| <script src="../static/js/webajax.js"></script> | |||
| <script src="../static/js/moment.min.js"></script> | |||
| <script src="../static/js/daterangepicker.js"></script> | |||
| <script src="js/main.js"></script> | |||
| @@ -248,7 +248,7 @@ function CheckCross() { | |||
| </tr> | |||
| <tr> | |||
| <td class="bline" height="26" style="padding-left:10px">文件保存目录:</td> | |||
| <td class="bline"><input name="typedir" type="text" id="typedir" value="<?php echo $myrow['typedir']?>" size="40" class="iptxt"></td> | |||
| <td class="bline"><input name="typedir" type="text" id="typedir" value="<?php echo $myrow['typedir']?>" size="40" class="iptxt">(填写{cmspath}/a/b/c生成目录“域名/a/b/c”标签{cmspath}必填)</td> | |||
| </tr> | |||
| <tr> | |||
| <td height="26" style="padding-left:10px">栏目列表选项:</td> | |||
| @@ -10,7 +10,7 @@ | |||
| <script src="js/context_menu.js"></script> | |||
| <script src="js/ieemu.js"></script> | |||
| <script src="js/dialog.js"></script> | |||
| <script src="../static/js/dedeajax2.js"></script> | |||
| <script src="../static/js/webajax.js"></script> | |||
| <script> | |||
| function LoadSuns(ctid,tid) | |||
| { | |||
| @@ -6,7 +6,7 @@ | |||
| <link href="css/base.css" rel="stylesheet" type="text/css" /> | |||
| <script language="javascript" src="js/context_menu.js"></script> | |||
| <script language="javascript" src="js/ieemu.js"></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <script language="javascript"> | |||
| function LoadSuns(ctid,tid) | |||
| { | |||
| @@ -8,7 +8,7 @@ | |||
| <link rel="stylesheet" href="css/base.css"> | |||
| <script src="js/context_menu.js"></script> | |||
| <script src="js/ieemu.js"></script> | |||
| <script src="../static/js/dedeajax2.js"></script> | |||
| <script src="../static/js/webajax.js"></script> | |||
| <script> | |||
| function LoadSuns(ctid,tid) | |||
| { | |||
| @@ -9,7 +9,7 @@ | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script src="../static/js/bootstrap.bundle.js"></script> | |||
| <script language='javascript' src="js/main.js"></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <script language="javascript" src="js/ieemu.js"></script> | |||
| <script language="javascript" src="js/context_menu.js"></script> | |||
| <script language="javascript" src="js/main.js"></script> | |||
| @@ -8,7 +8,7 @@ | |||
| <link rel="stylesheet" href="css/base.css"> | |||
| <script src="../static/js/jquery.js"></script> | |||
| <script src="../static/js/bootstrap.bundle.js"></script> | |||
| <script src="../static/js/dedeajax2.js"></script> | |||
| <script src="../static/js/webajax.js"></script> | |||
| <script src="js/ieemu.js"></script> | |||
| <script src="js/context_menu.js"></script> | |||
| <script src="js/main.js"></script> | |||
| @@ -8,7 +8,7 @@ | |||
| <link rel="stylesheet" type="text/css" href="css/base.css"> | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script src="../static/js/bootstrap.bundle.js"></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <script language="javascript" src="js/ieemu.js"></script> | |||
| <script language="javascript" src="js/context_menu.js"></script> | |||
| <script language="javascript" src="js/main.js"></script> | |||
| @@ -4,7 +4,7 @@ | |||
| <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $cfg_soft_lang; ?>"> | |||
| <title><?php echo $diy->name;?></title> | |||
| <link href="css/base.css" rel="stylesheet" type="text/css" /> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <script language="javascript" src="js/main.js"></script> | |||
| <script language="javascript"> | |||
| function SelectTemplets(fname){ | |||
| @@ -7,7 +7,7 @@ | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <script language="javascript" src="js/main.js"></script> | |||
| <script language="JavaScript"> | |||
| var pageno = 1; | |||
| @@ -35,17 +35,27 @@ | |||
| </div> | |||
| <div class="head"> | |||
| <div class="top"> | |||
| <div class="top_logo"><a href="javascript:;" onclick="JumpFrame('index_menu.php','index_body.php');"><?php echo $cfg_webname; ?>系统</a></div> | |||
| <div class="top_logo"><a target="main" href="index_body.php"><?php echo $cfg_webname; ?>系统</a></div> | |||
| <div class="top_version">V<?php echo $cfg_version_detail; ?></div> | |||
| <div class="top_link"> | |||
| <ul> | |||
| <li class="welcome"><img src="/static/img/avatar.png" title="<?php echo $cuserLogin->getUserName(); ?>"><?php echo $cuserLogin->getUserName(); ?><a href="exit.php">注销</a></li> | |||
| <li><a href="public_guide.php" target="main">发布文档</a></li> | |||
| <li><a href="content_list.php" target="main">所有文档</a></li> | |||
| <li><a href="catalog_main.php" target="main">栏目管理</a></li> | |||
| <li><a href="file_manage_main.php" target="main">文件管理</a></li> | |||
| <li><a href="templets_main.php" target="main">模板管理</a></li> | |||
| <?php echo ($cfg_mb_open=='Y')?'<li><a href="../member" target="_blank">会员中心</a></li>':''; ?> | |||
| <li class="welcome"> | |||
| <a target="main" href="sys_admin_user_edit.php?id=<?php echo $cuserLogin->getUserID(); ?>&dopost=edit"><img src="/static/img/avatar.png" title="<?php echo $cuserLogin->getUserName(); ?>"><?php echo $cuserLogin->getUserName(); ?></a> | |||
| <a href="exit.php">退出</a> | |||
| </li> | |||
| <?php | |||
| if($cuserLogin->getUserType()>=10){ | |||
| ?> | |||
| <li><a target="main" href="sys_info.php">系统配置</a></li> | |||
| <li><a target="main" href="catalog_main.php">栏目管理</a></li> | |||
| <li><a target="main" href="file_manage_main.php">文件管理</a></li> | |||
| <li><a target="main" href="templets_main.php">模板管理</a></li> | |||
| <?php | |||
| } | |||
| ?> | |||
| <li><a target="main" href="public_guide.php">发布文档</a></li> | |||
| <li><a target="main" href="makehtml_all.php">更新整站</a></li> | |||
| <?php echo ($cfg_mb_open=='Y')?'<li><a href="../user" target="_blank">会员中心</a></li>':''; ?> | |||
| <li><a href="../index.php?upcache=1" target="_blank">网站主页</a></li> | |||
| </ul> | |||
| </div> | |||
| @@ -53,19 +63,15 @@ | |||
| <div class="topnav"> | |||
| <div class="menuact"> | |||
| <a href="javascript:;" id="togglemenu">隐藏菜单</a> | |||
| <?php | |||
| if($cuserLogin->getUserType()>=10) echo'<a href="javascript:;" id="allmenu">功能地图</a>'; | |||
| ?> | |||
| </div> | |||
| <div id="skin"> | |||
| <div></div> | |||
| <a href="javascript:;" id="allmenu">功能地图</a> | |||
| </div> | |||
| <div id="skin"></div> | |||
| <div class="nav" id="nav"></div> | |||
| <div class="sysmsg"> | |||
| <div class="scroll"> | |||
| <form action="action_search.php" target="main" method="post"> | |||
| <input name="keyword" type="text" placeholder="功能搜索" class="allsearch"> | |||
| <input type="submit" value="搜索" class="np"> | |||
| <form action="action_search.php" method="post" target="main"> | |||
| <input type="text" name="keyword" placeholder="功能搜索" class="allsearch"> | |||
| <button type="submit" class="np">搜索</button> | |||
| <a href="<?php echo $cfg_biz_gitUrl; ?>" target="_blank">代码托管</a> | |||
| <a href="<?php echo $cfg_biz_helpUrl; ?>" target="_blank">帮助中心</a> | |||
| </form> | |||
| @@ -96,7 +102,7 @@ | |||
| $title = $ctag->GetAtt('title'); | |||
| $ico = $ctag->GetAtt('ico'); | |||
| $link = $ctag->GetAtt('link'); | |||
| echo "<li><a href='{$link}' target='main'>{$title}</a></li>\r\n"; | |||
| echo "<li><a target='main' href='{$link}'>{$title}</a></li>"; | |||
| } | |||
| } | |||
| ?> | |||
| @@ -11,7 +11,7 @@ | |||
| <link rel="stylesheet" href="css/indexbody.css"> | |||
| <script src="../static/js/jquery.js"></script> | |||
| <script src="../static/js/bootstrap.bundle.js"></script> | |||
| <script src="../static/js/dedeajax2.js"></script> | |||
| <script src="../static/js/webajax.js"></script> | |||
| <script src="js/indexbody.js"></script> | |||
| <script src="js/main.js"></script> | |||
| <style> | |||
| @@ -4,7 +4,7 @@ | |||
| <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $cfg_soft_lang; ?>"> | |||
| <title>DedeBIZ menu</title> | |||
| <link rel="stylesheet" href="css/base.css"> | |||
| <script src="../static/js/dedeajax2.js"></script> | |||
| <script src="../static/js/webajax.js"></script> | |||
| <script src="../static/js/jquery.js"></script> | |||
| <?php | |||
| echo "<script>var curopenItem = '$openitem';</script>"; | |||
| @@ -6,7 +6,7 @@ | |||
| <meta name="viewport" content="width=device-width,initial-scale=1,shrink-to-fit=no"> | |||
| <link rel="stylesheet" href="../static/css/bootstrap.min.css"> | |||
| <link rel="stylesheet" href="../static/font-awesome/css/font-awesome.min.css"> | |||
| <link rel="stylesheet" href="../static/css/dede.css"> | |||
| <link rel="stylesheet" href="../static/css/style.css"> | |||
| <title><?php echo $cfg_webname; ?>后台登录</title> | |||
| <style> | |||
| body{font:14px Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif;color:#424b51;background:#f2f2f2} | |||
| @@ -2,7 +2,7 @@ | |||
| <html xmlns="http://www.w3.org/1999/xhtml"> | |||
| <head> | |||
| <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $cfg_soft_lang; ?>"> | |||
| <title>生成HTML</title> | |||
| <title>更新文档</title> | |||
| <link rel="stylesheet" href="../static/css/bootstrap.min.css"> | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| @@ -17,7 +17,7 @@ | |||
| <td height="26" colspan="2" background='images/tbg.gif'> | |||
| <table width="98%" border="0" cellpadding="0" cellspacing="0" class="table table-borderless"> | |||
| <tr> | |||
| <td width="30%" height="18" style="padding-left:10px"><strong>更新文档H:</strong></td> | |||
| <td width="30%" height="18" style="padding-left:10px"><strong>更新文档:</strong></td> | |||
| <td width="70%" align="right"> | |||
| <a href="makehtml_list.php?typeid=<?php echo (isset($typeid) ? $typeid : 0); ?>" class="btn btn-success btn-sm">更新栏目</a> | |||
| </td> | |||
| @@ -56,7 +56,7 @@ | |||
| </tr> | |||
| <tr> | |||
| <td height="26" colspan="2" bgcolor="#ffffff" align="center"> | |||
| <button name="b112" type="button" class='btn btn-success' onClick="document.form1.submit();" >开始生成HTML</button> | |||
| <button name="b112" type="button" class='btn btn-success' onClick="document.form1.submit();" >开始更新</button> | |||
| | |||
| <button type="button" name="b113" class='btn btn-success' onClick="document.form2.submit();" >查看所有文档</button></td> | |||
| </tr> | |||
| @@ -2,7 +2,7 @@ | |||
| <html xmlns="http://www.w3.org/1999/xhtml"> | |||
| <head> | |||
| <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $cfg_soft_lang; ?>"> | |||
| <title>生成HTML</title> | |||
| <title>更新自由列表</title> | |||
| <link rel="stylesheet" href="../static/css/bootstrap.min.css"> | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| @@ -10,7 +10,7 @@ | |||
| <body background="images/allbg.gif"> | |||
| <div class="bodytitle mt-3"> | |||
| <div class="bodytitleleft"></div> | |||
| <div class="bodytitletxt" style="padding-left:10px">HTML更新</div> | |||
| <div class="bodytitletxt" style="padding-left:10px">更新自由列表</div> | |||
| </div> | |||
| <table width="98%" border="0" cellpadding="1" cellspacing="1" align="center" class="table maintable table-bordered" style="background:#CFCFCF;"> | |||
| <form name="form1" action="makehtml_freelist_action.php" method="get" target='stafrm'> | |||
| @@ -18,7 +18,7 @@ | |||
| <td colspan="2" bgcolor="#EDF9D5" background="images/tbg.gif"> | |||
| <table width="98%" border="0" cellpadding="0" cellspacing="0" class="table-borderless"> | |||
| <tr> | |||
| <td width="30%" height="18" style="padding-left:10px"><strong>更新自由列表HTML:</strong></td> | |||
| <td width="30%" height="18" style="padding-left:10px"><strong>更新自由列表:</strong></td> | |||
| <td width="70%" align="right"><button type="button" name="b113" onClick="location='freelist_main.php';" class="btn btn-success btn-sm">管理自由列表</button> | |||
| </td> | |||
| </tr> | |||
| @@ -49,7 +49,7 @@ | |||
| </tr> | |||
| <tr> | |||
| <td height="36" colspan="2" bgcolor="#ffffff" align="center"> | |||
| <button type="button" onClick="document.form1.submit();" class="btn btn-success">开始生成HTML</button> | |||
| <button type="button" onClick="document.form1.submit();" class="btn btn-success">开始更新</button> | |||
| </td> | |||
| </tr> | |||
| </form> | |||
| @@ -83,5 +83,4 @@ | |||
| </tr> | |||
| </table> | |||
| </body> | |||
| </html> | |||
| @@ -2,7 +2,7 @@ | |||
| <html xmlns="http://www.w3.org/1999/xhtml"> | |||
| <head> | |||
| <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $cfg_soft_lang; ?>"> | |||
| <title>首页更新向导</title> | |||
| <title>更新首页</title> | |||
| <script src="../static/js/jquery.js" language="javascript" type="text/javascript"></script> | |||
| <link rel="stylesheet" href="../static/css/bootstrap.min.css"> | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| @@ -27,7 +27,7 @@ | |||
| <td height="26" colspan="2" background='images/tbg.gif'> | |||
| <table width="98%" border="0" cellpadding="0" cellspacing="0" class="table table-borderless"> | |||
| <tr> | |||
| <td width="30%" height="18" style="padding-left:10px"><strong>首页更新向导:</strong></td> | |||
| <td width="30%" height="18" style="padding-left:10px"><strong>更新首页向导:</strong></td> | |||
| <td width="70%" align="right"> </td> | |||
| </tr> | |||
| </table> | |||
| @@ -117,8 +117,8 @@ | |||
| ?> | |||
| <tr> | |||
| <td height="30" colspan="2" bgcolor="#ffffff" align="center"> | |||
| <button name="view" class='btn btn-success' type="button" id="view" onClick="window.open('makehtml_homepage.php?dopost=view&templet='+form1.templet.value);">预览首页</button> | |||
| <button type="button" onclick="htmlSubmit()" class='btn btn-success' name="Submit">更新首页HTML</button> | |||
| <button name="view" class="btn btn-success" type="button" id="view" onClick="window.open('makehtml_homepage.php?dopost=view&templet='+form1.templet.value);">预览首页</button> | |||
| <button type="button" onclick="htmlSubmit()" class='btn btn-success' name="Submit">开始更新</button> | |||
| </td> | |||
| </tr> | |||
| </form> | |||
| @@ -2,7 +2,7 @@ | |||
| <html xmlns="http://www.w3.org/1999/xhtml"> | |||
| <head> | |||
| <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $cfg_soft_lang; ?>"> | |||
| <title>生成HTML</title> | |||
| <title>更新脚本</title> | |||
| <link rel="stylesheet" href="../static/css/bootstrap.min.css"> | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| @@ -73,8 +73,7 @@ | |||
| </tr> | |||
| <tr> | |||
| <td height="26" colspan="2" bgcolor="#ffffff" align="center"> | |||
| <button name="b112" type="button" class="btn btn-success" onClick="document.form1.submit();" | |||
| >生成/更新JS文件</button> | |||
| <button name="b112" type="button" class="btn btn-success" onClick="document.form1.submit();">开始更新</button> | |||
| </td> | |||
| </tr> | |||
| </form> | |||
| @@ -105,5 +104,4 @@ | |||
| </tr> | |||
| </table> | |||
| </body> | |||
| </html> | |||
| @@ -16,7 +16,7 @@ | |||
| <tr> | |||
| <td width="30%" height="18" style="padding-left:10px"><strong>更新栏目:</strong></td> | |||
| <td width="70%" align="right"> | |||
| <a href="makehtml_archives.php?typeid=<?php echo (isset($typeid) ? $typeid : 0); ?>" class="btn btn-success btn-sm">更新文档H</a> | |||
| <a href="makehtml_archives.php?typeid=<?php echo (isset($typeid) ? $typeid : 0); ?>" class="btn btn-success btn-sm">更新文档</a> | |||
| <a href="catalog_main.php" class="btn btn-success btn-sm">栏目管理</a> | |||
| </td> | |||
| </tr> | |||
| @@ -39,8 +39,7 @@ | |||
| </tr> | |||
| <tr> | |||
| <td height="26" valign="top" bgcolor="#FFFFFF">每次最大创建页数:</td> | |||
| <td height="26" valign="top" bgcolor="#FFFFFF"><input name="maxpagesize" type="text" id="maxpagesize" value="50" size="10"> | |||
| 个文件 </td> | |||
| <td height="26" valign="top" bgcolor="#FFFFFF"><input name="maxpagesize" type="text" id="maxpagesize" value="50" size="10"> 个文件</td> | |||
| </tr> | |||
| <tr> | |||
| <td height="26" valign="top" bgcolor="#FFFFFF">是否更新子栏目:</td> | |||
| @@ -53,7 +52,7 @@ | |||
| </tr> | |||
| <tr> | |||
| <td height="26" colspan="2" bgcolor="#ffffff" align="center"> | |||
| <button name="b112" type="button" class="btn btn-success" onClick="document.form1.submit();">开始生成HTML</button> | |||
| <button name="b112" type="button" class="btn btn-success" onClick="document.form1.submit();">开始更新</button> | |||
| </td> | |||
| </tr> | |||
| </form> | |||
| @@ -84,5 +83,4 @@ | |||
| </tr> | |||
| </table> | |||
| </body> | |||
| </html> | |||
| @@ -30,7 +30,7 @@ | |||
| </tr> | |||
| <tr> | |||
| <td height="26" bgcolor="#ffffff" align="center"> | |||
| <button name="b112" type="button" class="btn btn-success" onClick="document.form1.submit();">开始生成HTML</button> | |||
| <button name="b112" type="button" class="btn btn-success" onClick="document.form1.submit();">开始更新</button> | |||
| </td> | |||
| </tr> | |||
| </form> | |||
| @@ -4,7 +4,7 @@ | |||
| <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $cfg_soft_lang; ?>"> | |||
| <link rel="stylesheet" href="../static/css/bootstrap.min.css"> | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <script language="javascript"> | |||
| function ShowHideField(cbox,vid,nid) | |||
| { | |||
| @@ -2,7 +2,7 @@ | |||
| <html xmlns="http://www.w3.org/1999/xhtml"> | |||
| <head> | |||
| <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $cfg_soft_lang; ?>"> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <script language="javascript"> | |||
| function LoadHashCode() { | |||
| var tgobj = document.getElementById('modulcode'); | |||
| @@ -8,7 +8,7 @@ | |||
| <link rel="stylesheet" href="css/base.css"> | |||
| <script src="../static/js/jquery.min.js"></script> | |||
| <script src="../static/js/bootstrap.bundle.js"></script> | |||
| <script src="../static/js/dedeajax2.js"></script> | |||
| <script src="../static/js/webajax.js"></script> | |||
| <script> | |||
| function getmodule(action, hash) { | |||
| $DE('status_' + hash).innerHTML = '<img src=\'images/loadinglit.gif\'>'; | |||
| @@ -4,7 +4,7 @@ | |||
| <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $cfg_soft_lang; ?>"> | |||
| <link rel="stylesheet" href="../static/css/bootstrap.min.css"> | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <script language="javascript"> | |||
| function ShowHideField(cbox, vid, nid) { | |||
| var cboxobj = document.getElementById(cbox); | |||
| @@ -9,7 +9,7 @@ | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script language="javascript" src="../static/js/bootstrap.bundle.js"></script> | |||
| <script language="javascript" src="js/key.js"></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <script language='javascript' src='js/main.js'></script> | |||
| <script language="JavaScript"> | |||
| var pageno = 1; | |||
| @@ -8,7 +8,7 @@ | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script src="../static/js/bootstrap.bundle.js"></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <link href="../static/css/daterangepicker.css" rel="stylesheet"> | |||
| <script type="text/javascript" src="../static/js/moment.min.js"></script> | |||
| <script type="text/javascript" src="../static/js/daterangepicker.js"></script> | |||
| @@ -439,15 +439,11 @@ table{border-collapse:separate} | |||
| <tr> | |||
| <td width="90"> 附加选项:</td> | |||
| <td> | |||
| <label><input name="remote" type="checkbox" class="np" id="remote" value="1" | |||
| <?php if($cfg_rm_remote=='Y') echo ' checked'; ?>> | |||
| 下载远程图片和资源</label> | |||
| <label><input name="dellink" type="checkbox" class="np" id="dellink" value="1" | |||
| <?php if($cfg_arc_dellink=='Y') echo ' checked'; ?>> | |||
| 删除非站内链接</label> <a class='btn btn-success btn-sm' href="javascript:OpenMyWin('article_allowurl_edit.php');">设置</a> | |||
| <label><input name="autolitpic" type="checkbox" class="np" id="autolitpic" value="1" | |||
| <?php if($cfg_arc_autopic=='Y') echo ' checked'; ?>> | |||
| 提取第一个图片为缩略图</label> </td> | |||
| <label><input name="remote" type="checkbox" class="np" id="remote" value="1" <?php if($cfg_rm_remote=='Y') echo ' checked'; ?>> 下载远程图片和资源 </label> | |||
| <label><input name="dellink" type="checkbox" class="np" id="dellink" value="1" <?php if($cfg_arc_dellink=='Y') echo ' checked'; ?>> 删除非站内链接</label> | |||
| <a href="javascript:OpenMyWin('article_allowurl_edit.php');" class="btn btn-success btn-sm">设置</a> | |||
| <label><input name="autolitpic" type="checkbox" class="np" id="autolitpic" value="1" <?php if($cfg_arc_autopic=='Y') echo ' checked'; ?>> 提取第一个图片为缩略图</label> | |||
| </td> | |||
| </tr> | |||
| </table> | |||
| </td> | |||
| @@ -8,7 +8,7 @@ | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script src="../static/js/bootstrap.bundle.js"></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <link href="../static/css/daterangepicker.css" rel="stylesheet"> | |||
| <link rel="stylesheet" href="../static/css/jquery.fileupload.css"> | |||
| <script type="text/javascript" src="../static/js/moment.min.js"></script> | |||
| @@ -12,7 +12,7 @@ | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <link rel="stylesheet" href="../static/css/jquery.fileupload.css"> | |||
| <link href="../static/css/daterangepicker.css" rel="stylesheet"> | |||
| <script type="text/javascript" src="../static/js/moment.min.js"></script> | |||
| @@ -12,7 +12,7 @@ | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <link href="../static/css/daterangepicker.css" rel="stylesheet"> | |||
| <link rel="stylesheet" href="../static/css/jquery.fileupload.css"> | |||
| <script type="text/javascript" src="../static/js/moment.min.js"></script> | |||
| @@ -35,7 +35,7 @@ | |||
| margin: 5px; | |||
| } | |||
| </style> | |||
| <SCRIPT LANGUAGE="JavaScript" src="../static/js/dedeajax2.js"></SCRIPT> | |||
| <SCRIPT LANGUAGE="JavaScript" src="../static/js/webajax.js"></SCRIPT> | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script src="../static/js/bootstrap.bundle.js"></script> | |||
| <script language='javascript' src='js/main.js'></script> | |||
| @@ -6,7 +6,7 @@ | |||
| <link rel="stylesheet" href="../static/css/bootstrap.min.css"> | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| <script language='javascript' src='../static/js/dedeajax2.js'></script> | |||
| <script language='javascript' src='../static/js/webajax.js'></script> | |||
| <script language='javascript'> | |||
| //gcontainer,mShowError,mShowWait,mErrCon,mErrDisplay,mWaitDisplay | |||
| function LoadUser(uid) | |||
| @@ -6,7 +6,7 @@ | |||
| <link rel="stylesheet" href="../static/css/bootstrap.min.css"> | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link href='css/base.css' rel='stylesheet' type='text/css'> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <script language="javascript"> | |||
| var myajax; | |||
| var newobj; | |||
| @@ -6,7 +6,7 @@ | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script language="javascript" src="../static/js/bootstrap.bundle.js"></script> | |||
| <script language="javascript" src="js/main.js"></script> | |||
| <script language='javascript' src='../static/js/dedeajax2.js'></script> | |||
| <script language='javascript' src='../static/js/webajax.js'></script> | |||
| <script language='javascript'> | |||
| function ShowFields() { | |||
| var exptable = $DE('exptable').options[$DE('exptable').selectedIndex].value; | |||
| @@ -3,7 +3,7 @@ | |||
| <head> | |||
| <meta charset="<?php echo $cfg_soft_lang; ?>"> | |||
| <title>系统配置变量</title> | |||
| <script src="../static/js/dedeajax2.js"></script> | |||
| <script src="../static/js/webajax.js"></script> | |||
| <script src="../static/js/jquery.js"></script> | |||
| <script> | |||
| var searchconfig = false; | |||
| @@ -14,7 +14,7 @@ | |||
| </style> | |||
| <script language="javascript" src="../static/js/jquery.js"></script> | |||
| <script language='javascript' src='js/main.js'></script> | |||
| <script language="javascript" src="../static/js/dedeajax2.js"></script> | |||
| <script language="javascript" src="../static/js/webajax.js"></script> | |||
| <script language='javascript'> | |||
| function LoadCtTest() { | |||
| var filetype = $Obj('filetype').value; | |||
| @@ -6,7 +6,7 @@ | |||
| <script src="../static/js/jquery.js" language="javascript" type="text/javascript"></script> | |||
| <script src="/static/js/bootstrap.bundle.js"></script> | |||
| <link rel="stylesheet" href="../static/css/bootstrap.min.css"> | |||
| <script src="../static/js/dede.js"></script> | |||
| <script src="../static/js/style.js"></script> | |||
| <link href="../static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link href="css/base.css" rel="stylesheet" type="text/css" /> | |||
| <style> | |||
| @@ -5,7 +5,7 @@ | |||
| <title>自动更新程序--待下载文件列表</title> | |||
| <link href="css/base.css" rel="stylesheet" type="text/css"> | |||
| <link rel="stylesheet" type="text/css" href="css/indexbody.css"> | |||
| <script language='javascript' src='../static/js/dedeajax2.js'></script> | |||
| <script language='javascript' src='../static/js/webajax.js'></script> | |||
| <script language='javascript' src='js/indexbody.js'></script> | |||
| </head> | |||
| <body background="images/allbg.gif" leftmargin='8' topmargin='8'> | |||
| @@ -9,7 +9,7 @@ $cfg_webname = '~webname~'; | |||
| $cfg_adminemail = '~adminmail~'; | |||
| $cfg_html_editor = 'ckeditor'; | |||
| $cfg_arcdir = '/a'; | |||
| $cfg_medias_dir = '/uploads'; | |||
| $cfg_medias_dir = '/static'; | |||
| $cfg_ddimg_width = 400; | |||
| $cfg_ddimg_height = 300; | |||
| $cfg_domain_cookie = ''; | |||
| @@ -3951,7 +3951,7 @@ INSERT INTO `#@__sysconfig` VALUES('1','cfg_basehost','站点网址(http://域 | |||
| ('8','cfg_adminemail','网站发信邮箱','2','string','support@dedebiz.com'), | |||
| ('9','cfg_html_editor','富文本','2','string','ckeditor'), | |||
| ('10','cfg_arcdir','默认文档生成文件路径','1','string','/a'), | |||
| ('11','cfg_medias_dir','默认图片上传文件路径','1','string','/uploads'), | |||
| ('11','cfg_medias_dir','默认图片上传文件路径','1','string','/static'), | |||
| ('12','cfg_ddimg_width','缩略图默认宽度','3','number','400'), | |||
| ('13','cfg_ddimg_height','缩略图默认高度','3','number','300'), | |||
| ('63','cfg_album_width','图集默认显示图片的大小','3','number','800'), | |||
| @@ -8,7 +8,7 @@ | |||
| <script src="../static/js/jquery.min.js"></script> | |||
| <script src="../static/js/popper.min.js"></script> | |||
| <script src="../static/js/bootstrap.bundle.js"></script> | |||
| <script src="../static/js/dede.js"></script> | |||
| <script src="../static/js/style.js"></script> | |||
| <style>body{font:14px Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif;color:#343a40;background:#f2f2f2}input,select,.btn{font-size:14px!important}@media (min-width:1200px){.container{max-width:950px}}</style> | |||
| </head> | |||
| <body> | |||
| @@ -1 +1 @@ | |||
| *{font-size:12px;letter-spacing:.4px}body{font:12px Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif;color:#424b51;background:#fff;line-height:1.5}form,h1,h2,h3,ul,ol,div{margin:0;padding:0}td{line-height:1.5}td,th,div{word-break:break-all;word-wrap:break-word}b,strong{font-weight:400}li,dd{margin:0;padding:0;list-style-type:none}label{display:inline-block;margin:10px 0}input{padding:.25rem .5rem;height:calc(1.5em + .75rem + 2px);line-height:18px;color:#424b51;background:#fff;border:1px solid #eee;border-radius:.2rem;transition:all .6s;vertical-align:middle}input[type=radio],input[type=checkbox]{height:auto;box-shadow:none;outline:none}input[type=button],input[type=submit],input[type=reset]{padding:.25rem .5rem;height:auto;line-height:1.5;color:#fff;background:#28a745;border-radius:.2rem;transition:all .6s;border:0}input[type=button]:focus,input[type=submit]:focus,input[type=reset]:focus{background:#006829;border-color:#005b24;box-shadow:0 0 0 0.2rem rgba(38,159,86,.5)}input:focus,textarea:focus{border-color:#28a745;box-shadow:0 0 2px #28a745;outline:none}textarea{padding:.25rem .5rem;line-height:18px;font-family:Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif;color:#424b51;background:#fff;border:1px solid #eee;border-radius:.2rem;transition:all .6s;vertical-align:middle}select{height:calc(1.5em + .75rem + 2px);padding:.25rem .5rem;color:#424b51;background:#fff;border:1px solid #eee;border-radius:.2rem;transition:all .6s}img{margin-right:6px;border-radius:.2rem;vertical-align:baseline}h1,h2,h3{font-size:18px;color:#424b51}a:link{color:#424b51;text-decoration:none}a:hover{opacity:.8}a:visited{color:#666}.m1{border-left:1px solid #DFDFDB;border-top:1px solid #DFDFDB;border-bottom:1px solid #808080}.m2{border-left:1px solid #DFDFDB;border-bottom:1px solid #808080;border-top:1px solid #DFDFDB;border-right:1px solid #DFDFDB}.m3{border-left:1px solid #DFDFDB;border-top:1px solid #DFDFDB;border-right:1px solid #DFDFDB}.article{line-height:160%;table-layout:fixed;word-break:break-all}.bn{color:#fff;line-height:50%}.contents{color:#F7F6F8}.nb{border:1px solid #ccc}.coolbg{border-right:2px solid #ACACAC;border-bottom:2px solid #ACACAC;background-color:#E6E6E6}.ctfield{padding:2px;line-height:150%}.nndiv{width:170px;height:20px;margin:0;padding:0;word-break:break-all;overflow:hidden}.maintable{width:98%!important}a.btn{color:white!important} | |||
| *{font-size:12px;letter-spacing:.4px}body{line-height:1.5;font:12px Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif;color:#424b51;background:#fff}form,h1,h2,h3,ul,ol,div{margin:0;padding:0}td{line-height:1.5}td,th,div{word-break:break-all;word-wrap:break-word}b,strong{font-weight:400}li,dd{margin:0;padding:0;list-style-type:none}label{display:inline-block;margin:10px 0}input{padding:.25rem .5rem;height:calc(1.5em + .75rem + 2px);line-height:18px;color:#424b51;background:#fff;border:1px solid #eee;border-radius:.2rem;transition:all .6s;vertical-align:middle}input[type=radio],input[type=checkbox]{height:auto;box-shadow:none;outline:none}input[type=button],input[type=submit],input[type=reset]{padding:.25rem .5rem;height:auto;line-height:1.5;color:#fff;background:#28a745;border-radius:.2rem;transition:all .6s;border:0}input[type=button]:focus,input[type=submit]:focus,input[type=reset]:focus{background:#006829;border-color:#005b24;box-shadow:0 0 0 0.2rem rgba(38,159,86,.5)}input:focus,textarea:focus{border-color:#28a745;box-shadow:0 0 2px #28a745;outline:none}textarea{padding:.25rem .5rem;line-height:18px;font-family:Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif;color:#424b51;background:#fff;border:1px solid #eee;border-radius:.2rem;transition:all .6s;vertical-align:middle}select{height:calc(1.5em + .75rem + 2px);padding:.25rem .5rem;color:#424b51;background:#fff;border:1px solid #eee;border-radius:.2rem;transition:all .6s}h1,h2,h3{font-size:18px;color:#424b51}a:link{color:#424b51;text-decoration:none}a:hover{opacity:.8}a:visited{color:#666}.m1{border-left:1px solid #DFDFDB;border-top:1px solid #DFDFDB;border-bottom:1px solid #808080}.m2{border-left:1px solid #DFDFDB;border-bottom:1px solid #808080;border-top:1px solid #DFDFDB;border-right:1px solid #DFDFDB}.m3{border-left:1px solid #DFDFDB;border-top:1px solid #DFDFDB;border-right:1px solid #DFDFDB}.article{line-height:160%;table-layout:fixed;word-break:break-all}.bn{color:#fff;line-height:50%}.contents{color:#F7F6F8}.nb{border:1px solid #ccc}.coolbg{border-right:2px solid #ACACAC;border-bottom:2px solid #ACACAC;background-color:#E6E6E6}.ctfield{padding:2px;line-height:150%}.nndiv{width:170px;height:20px;margin:0;padding:0;word-break:break-all;overflow:hidden}.maintable{width:98%!important}a.btn{color:white!important} | |||
| @@ -1,281 +1,281 @@ | |||
| <!-- | |||
| //xmlhttp和xmldom对象 | |||
| var DedeXHTTP = null; | |||
| var DedeXDOM = null; | |||
| var DedeContainer = null; | |||
| var DedeShowError = false; | |||
| var DedeShowWait = false; | |||
| var DedeErrCon = ""; | |||
| var DedeErrDisplay = "下载数据失败"; | |||
| var DedeWaitDisplay = "正在下载数据..."; | |||
| //获取指定ID的元素 | |||
| function $DE(id) { | |||
| return document.getElementById(id); | |||
| } | |||
| //gcontainer 是保存下载完成的内容的容器 | |||
| //mShowError 是否提示错误信息 | |||
| //DedeShowWait 是否提示等待信息 | |||
| //mErrCon 服务器返回什么字符串视为错误 | |||
| //mErrDisplay 发生错误时显示的信息 | |||
| //mWaitDisplay 等待时提示信息 | |||
| //默认调用 DedeAjax('divid',false,false,'','','') | |||
| function DedeAjax(gcontainer,mShowError,mShowWait,mErrCon,mErrDisplay,mWaitDisplay) | |||
| { | |||
| DedeContainer = gcontainer; | |||
| DedeShowError = mShowError; | |||
| DedeShowWait = mShowWait; | |||
| if(mErrCon!="") DedeErrCon = mErrCon; | |||
| if(mErrDisplay!="") DedeErrDisplay = mErrDisplay; | |||
| if(mErrDisplay=="x") DedeErrDisplay = ""; | |||
| if(mWaitDisplay!="") DedeWaitDisplay = mWaitDisplay; | |||
| //post或get发送数据的键值对 | |||
| this.keys = Array(); | |||
| this.values = Array(); | |||
| this.keyCount = -1; | |||
| this.sendlang = 'gb2312'; | |||
| //请求头类型 | |||
| this.rtype = 'text'; | |||
| //初始化xmlhttp | |||
| //IE6、IE5 | |||
| if(window.ActiveXObject) { | |||
| try { DedeXHTTP = new ActiveXObject("Msxml2.XMLHTTP");} catch (e) { } | |||
| if (DedeXHTTP == null) try { DedeXHTTP = new ActiveXObject("Microsoft.XMLHTTP");} catch (e) { } | |||
| } | |||
| else { | |||
| DedeXHTTP = new XMLHttpRequest(); | |||
| } | |||
| //增加一个POST或GET键值对 | |||
| this.AddKeyN = function(skey,svalue) { | |||
| if(this.sendlang=='utf-8') this.AddKeyUtf8(skey, svalue); | |||
| else this.AddKey(skey, svalue); | |||
| }; | |||
| this.AddKey = function(skey,svalue) { | |||
| this.keyCount++; | |||
| this.keys[this.keyCount] = skey; | |||
| svalue = svalue+''; | |||
| if(svalue != '') svalue = svalue.replace(/\+/g,'$#$'); | |||
| this.values[this.keyCount] = escape(svalue); | |||
| }; | |||
| //增加一个POST或GET键值对 | |||
| this.AddKeyUtf8 = function(skey,svalue) { | |||
| this.keyCount++; | |||
| this.keys[this.keyCount] = skey; | |||
| svalue = svalue+''; | |||
| if(svalue != '') svalue = svalue.replace(/\+/g,'$#$'); | |||
| this.values[this.keyCount] = encodeURI(svalue); | |||
| }; | |||
| //增加一个Http请求头键值对 | |||
| this.AddHead = function(skey,svalue) { | |||
| this.rkeyCount++; | |||
| this.rkeys[this.rkeyCount] = skey; | |||
| this.rvalues[this.rkeyCount] = svalue; | |||
| }; | |||
| //清除当前对象的哈希表参数 | |||
| this.ClearSet = function() { | |||
| this.keyCount = -1; | |||
| this.keys = Array(); | |||
| this.values = Array(); | |||
| this.rkeyCount = -1; | |||
| this.rkeys = Array(); | |||
| this.rvalues = Array(); | |||
| }; | |||
| DedeXHTTP.onreadystatechange = function() { | |||
| //在IE6中不管阻断或异步模式都会执行这个事件的 | |||
| if(DedeXHTTP.readyState == 4){ | |||
| if(DedeXHTTP.status == 200) | |||
| { | |||
| if(DedeXHTTP.responseText!=DedeErrCon) { | |||
| DedeContainer.innerHTML = DedeXHTTP.responseText; | |||
| } | |||
| else { | |||
| if(DedeShowError) DedeContainer.innerHTML = DedeErrDisplay; | |||
| } | |||
| DedeXHTTP = null; | |||
| } | |||
| else { if(DedeShowError) DedeContainer.innerHTML = DedeErrDisplay; } | |||
| } | |||
| else { if(DedeShowWait) DedeContainer.innerHTML = DedeWaitDisplay; } | |||
| }; | |||
| //检测阻断模式的状态 | |||
| this.BarrageStat = function() { | |||
| if(DedeXHTTP==null) return; | |||
| if(typeof(DedeXHTTP.status)!=undefined && DedeXHTTP.status == 200) | |||
| { | |||
| if(DedeXHTTP.responseText!=DedeErrCon) { | |||
| DedeContainer.innerHTML = DedeXHTTP.responseText; | |||
| } | |||
| else { | |||
| if(DedeShowError) DedeContainer.innerHTML = DedeErrDisplay; | |||
| } | |||
| } | |||
| }; | |||
| //发送http请求头 | |||
| this.SendHead = function() | |||
| { | |||
| //发送用户自行设定的请求头 | |||
| if(this.rkeyCount!=-1) | |||
| { | |||
| for(var i = 0;i<=this.rkeyCount;i++) | |||
| { | |||
| DedeXHTTP.setRequestHeader(this.rkeys[i],this.rvalues[i]); | |||
| } | |||
| } | |||
| if(this.rtype=='binary'){ | |||
| DedeXHTTP.setRequestHeader("Content-Type","multipart/form-data"); | |||
| }else{ | |||
| DedeXHTTP.setRequestHeader("Content-Type","application/x-www-form-urlencoded"); | |||
| } | |||
| }; | |||
| //用Post方式发送数据 | |||
| this.SendPost = function(purl) { | |||
| var pdata = ""; | |||
| var i=0; | |||
| this.state = 0; | |||
| DedeXHTTP.open("POST", purl, true); | |||
| this.SendHead(); | |||
| //post数据 | |||
| if(this.keyCount!=-1) | |||
| { | |||
| for(;i<=this.keyCount;i++) | |||
| { | |||
| if(pdata=="") pdata = this.keys[i]+'='+this.values[i]; | |||
| else pdata += "&"+this.keys[i]+'='+this.values[i]; | |||
| } | |||
| } | |||
| DedeXHTTP.send(pdata); | |||
| }; | |||
| //用GET方式发送数据 | |||
| this.SendGet = function(purl) { | |||
| var gkey = ""; | |||
| var i=0; | |||
| this.state = 0; | |||
| //get参数 | |||
| if(this.keyCount!=-1) | |||
| { | |||
| for(;i<=this.keyCount;i++) | |||
| { | |||
| if(gkey=="") gkey = this.keys[i]+'='+this.values[i]; | |||
| else gkey += "&"+this.keys[i]+'='+this.values[i]; | |||
| } | |||
| if(purl.indexOf('?')==-1) purl = purl + '?' + gkey; | |||
| else purl = purl + '&' + gkey; | |||
| } | |||
| DedeXHTTP.open("GET", purl, true); | |||
| this.SendHead(); | |||
| DedeXHTTP.send(null); | |||
| }; | |||
| //用GET方式发送数据,阻塞模式 | |||
| this.SendGet2 = function(purl) { | |||
| var gkey = ""; | |||
| var i=0; | |||
| this.state = 0; | |||
| //get参数 | |||
| if(this.keyCount!=-1) | |||
| { | |||
| for(;i<=this.keyCount;i++) | |||
| { | |||
| if(gkey=="") gkey = this.keys[i]+'='+this.values[i]; | |||
| else gkey += "&"+this.keys[i]+'='+this.values[i]; | |||
| } | |||
| if(purl.indexOf('?')==-1) purl = purl + '?' + gkey; | |||
| else purl = purl + '&' + gkey; | |||
| } | |||
| DedeXHTTP.open("GET", purl, false); | |||
| this.SendHead(); | |||
| DedeXHTTP.send(null); | |||
| //firefox中直接检测XHTTP状态 | |||
| this.BarrageStat(); | |||
| }; | |||
| //用Post方式发送数据 | |||
| this.SendPost2 = function(purl) { | |||
| var pdata = ""; | |||
| var i=0; | |||
| this.state = 0; | |||
| DedeXHTTP.open("POST", purl, false); | |||
| this.SendHead(); | |||
| //post数据 | |||
| if(this.keyCount!=-1) | |||
| { | |||
| for(;i<=this.keyCount;i++) | |||
| { | |||
| if(pdata=="") pdata = this.keys[i]+'='+this.values[i]; | |||
| else pdata += "&"+this.keys[i]+'='+this.values[i]; | |||
| } | |||
| } | |||
| DedeXHTTP.send(pdata); | |||
| //firefox中直接检测XHTTP状态 | |||
| this.BarrageStat(); | |||
| }; | |||
| } // End Class DedeAjax | |||
| //初始化xmldom | |||
| function InitXDom() { | |||
| if(DedeXDOM!=null) return; | |||
| var obj = null; | |||
| // Gecko、Mozilla、Firefox | |||
| if (typeof(DOMParser) != "undefined") { | |||
| var parser = new DOMParser(); | |||
| obj = parser.parseFromString(xmlText, "text/xml"); | |||
| } | |||
| // IE | |||
| else { | |||
| try { obj = new ActiveXObject("MSXML2.DOMDocument");} catch (e) { } | |||
| if (obj == null) try { obj = new ActiveXObject("Microsoft.XMLDOM"); } catch (e) { } | |||
| } | |||
| DedeXDOM = obj; | |||
| }; | |||
| //读写cookie函数 | |||
| function GetCookie(c_name) | |||
| { | |||
| if (document.cookie.length > 0) | |||
| { | |||
| c_start = document.cookie.indexOf(c_name + "=") | |||
| if (c_start != -1) | |||
| { | |||
| c_start = c_start + c_name.length + 1; | |||
| c_end = document.cookie.indexOf(";",c_start); | |||
| if (c_end == -1) | |||
| { | |||
| c_end = document.cookie.length; | |||
| } | |||
| return unescape(document.cookie.substring(c_start,c_end)); | |||
| } | |||
| } | |||
| return null | |||
| } | |||
| function SetCookie(c_name,value,expiredays) | |||
| { | |||
| var exdate = new Date(); | |||
| exdate.setDate(exdate.getDate() + expiredays); | |||
| document.cookie = c_name + "=" +escape(value) + ((expiredays == null) ? "" : ";expires=" + exdate.toGMTString()); //使设置的有效时间正确。增加toGMTString() | |||
| } | |||
| --> | |||
| <!-- | |||
| //xmlhttp和xmldom对象 | |||
| var DedeXHTTP = null; | |||
| var DedeXDOM = null; | |||
| var DedeContainer = null; | |||
| var DedeShowError = false; | |||
| var DedeShowWait = false; | |||
| var DedeErrCon = ""; | |||
| var DedeErrDisplay = "下载数据失败"; | |||
| var DedeWaitDisplay = "正在下载数据..."; | |||
| //获取指定ID的元素 | |||
| function $DE(id) { | |||
| return document.getElementById(id); | |||
| } | |||
| //gcontainer 是保存下载完成的内容的容器 | |||
| //mShowError 是否提示错误信息 | |||
| //DedeShowWait 是否提示等待信息 | |||
| //mErrCon 服务器返回什么字符串视为错误 | |||
| //mErrDisplay 发生错误时显示的信息 | |||
| //mWaitDisplay 等待时提示信息 | |||
| //默认调用 DedeAjax('divid',false,false,'','','') | |||
| function DedeAjax(gcontainer,mShowError,mShowWait,mErrCon,mErrDisplay,mWaitDisplay) | |||
| { | |||
| DedeContainer = gcontainer; | |||
| DedeShowError = mShowError; | |||
| DedeShowWait = mShowWait; | |||
| if(mErrCon!="") DedeErrCon = mErrCon; | |||
| if(mErrDisplay!="") DedeErrDisplay = mErrDisplay; | |||
| if(mErrDisplay=="x") DedeErrDisplay = ""; | |||
| if(mWaitDisplay!="") DedeWaitDisplay = mWaitDisplay; | |||
| //post或get发送数据的键值对 | |||
| this.keys = Array(); | |||
| this.values = Array(); | |||
| this.keyCount = -1; | |||
| this.sendlang = 'gb2312'; | |||
| //请求头类型 | |||
| this.rtype = 'text'; | |||
| //初始化xmlhttp | |||
| //IE6、IE5 | |||
| if(window.ActiveXObject) { | |||
| try { DedeXHTTP = new ActiveXObject("Msxml2.XMLHTTP");} catch (e) { } | |||
| if (DedeXHTTP == null) try { DedeXHTTP = new ActiveXObject("Microsoft.XMLHTTP");} catch (e) { } | |||
| } | |||
| else { | |||
| DedeXHTTP = new XMLHttpRequest(); | |||
| } | |||
| //增加一个POST或GET键值对 | |||
| this.AddKeyN = function(skey,svalue) { | |||
| if(this.sendlang=='utf-8') this.AddKeyUtf8(skey, svalue); | |||
| else this.AddKey(skey, svalue); | |||
| }; | |||
| this.AddKey = function(skey,svalue) { | |||
| this.keyCount++; | |||
| this.keys[this.keyCount] = skey; | |||
| svalue = svalue+''; | |||
| if(svalue != '') svalue = svalue.replace(/\+/g,'$#$'); | |||
| this.values[this.keyCount] = escape(svalue); | |||
| }; | |||
| //增加一个POST或GET键值对 | |||
| this.AddKeyUtf8 = function(skey,svalue) { | |||
| this.keyCount++; | |||
| this.keys[this.keyCount] = skey; | |||
| svalue = svalue+''; | |||
| if(svalue != '') svalue = svalue.replace(/\+/g,'$#$'); | |||
| this.values[this.keyCount] = encodeURI(svalue); | |||
| }; | |||
| //增加一个Http请求头键值对 | |||
| this.AddHead = function(skey,svalue) { | |||
| this.rkeyCount++; | |||
| this.rkeys[this.rkeyCount] = skey; | |||
| this.rvalues[this.rkeyCount] = svalue; | |||
| }; | |||
| //清除当前对象的哈希表参数 | |||
| this.ClearSet = function() { | |||
| this.keyCount = -1; | |||
| this.keys = Array(); | |||
| this.values = Array(); | |||
| this.rkeyCount = -1; | |||
| this.rkeys = Array(); | |||
| this.rvalues = Array(); | |||
| }; | |||
| DedeXHTTP.onreadystatechange = function() { | |||
| //在IE6中不管阻断或异步模式都会执行这个事件的 | |||
| if(DedeXHTTP.readyState == 4){ | |||
| if(DedeXHTTP.status == 200) | |||
| { | |||
| if(DedeXHTTP.responseText!=DedeErrCon) { | |||
| DedeContainer.innerHTML = DedeXHTTP.responseText; | |||
| } | |||
| else { | |||
| if(DedeShowError) DedeContainer.innerHTML = DedeErrDisplay; | |||
| } | |||
| DedeXHTTP = null; | |||
| } | |||
| else { if(DedeShowError) DedeContainer.innerHTML = DedeErrDisplay; } | |||
| } | |||
| else { if(DedeShowWait) DedeContainer.innerHTML = DedeWaitDisplay; } | |||
| }; | |||
| //检测阻断模式的状态 | |||
| this.BarrageStat = function() { | |||
| if(DedeXHTTP==null) return; | |||
| if(typeof(DedeXHTTP.status)!=undefined && DedeXHTTP.status == 200) | |||
| { | |||
| if(DedeXHTTP.responseText!=DedeErrCon) { | |||
| DedeContainer.innerHTML = DedeXHTTP.responseText; | |||
| } | |||
| else { | |||
| if(DedeShowError) DedeContainer.innerHTML = DedeErrDisplay; | |||
| } | |||
| } | |||
| }; | |||
| //发送http请求头 | |||
| this.SendHead = function() | |||
| { | |||
| //发送用户自行设定的请求头 | |||
| if(this.rkeyCount!=-1) | |||
| { | |||
| for(var i = 0;i<=this.rkeyCount;i++) | |||
| { | |||
| DedeXHTTP.setRequestHeader(this.rkeys[i],this.rvalues[i]); | |||
| } | |||
| } | |||
| if(this.rtype=='binary'){ | |||
| DedeXHTTP.setRequestHeader("Content-Type","multipart/form-data"); | |||
| }else{ | |||
| DedeXHTTP.setRequestHeader("Content-Type","application/x-www-form-urlencoded"); | |||
| } | |||
| }; | |||
| //用Post方式发送数据 | |||
| this.SendPost = function(purl) { | |||
| var pdata = ""; | |||
| var i=0; | |||
| this.state = 0; | |||
| DedeXHTTP.open("POST", purl, true); | |||
| this.SendHead(); | |||
| //post数据 | |||
| if(this.keyCount!=-1) | |||
| { | |||
| for(;i<=this.keyCount;i++) | |||
| { | |||
| if(pdata=="") pdata = this.keys[i]+'='+this.values[i]; | |||
| else pdata += "&"+this.keys[i]+'='+this.values[i]; | |||
| } | |||
| } | |||
| DedeXHTTP.send(pdata); | |||
| }; | |||
| //用GET方式发送数据 | |||
| this.SendGet = function(purl) { | |||
| var gkey = ""; | |||
| var i=0; | |||
| this.state = 0; | |||
| //get参数 | |||
| if(this.keyCount!=-1) | |||
| { | |||
| for(;i<=this.keyCount;i++) | |||
| { | |||
| if(gkey=="") gkey = this.keys[i]+'='+this.values[i]; | |||
| else gkey += "&"+this.keys[i]+'='+this.values[i]; | |||
| } | |||
| if(purl.indexOf('?')==-1) purl = purl + '?' + gkey; | |||
| else purl = purl + '&' + gkey; | |||
| } | |||
| DedeXHTTP.open("GET", purl, true); | |||
| this.SendHead(); | |||
| DedeXHTTP.send(null); | |||
| }; | |||
| //用GET方式发送数据,阻塞模式 | |||
| this.SendGet2 = function(purl) { | |||
| var gkey = ""; | |||
| var i=0; | |||
| this.state = 0; | |||
| //get参数 | |||
| if(this.keyCount!=-1) | |||
| { | |||
| for(;i<=this.keyCount;i++) | |||
| { | |||
| if(gkey=="") gkey = this.keys[i]+'='+this.values[i]; | |||
| else gkey += "&"+this.keys[i]+'='+this.values[i]; | |||
| } | |||
| if(purl.indexOf('?')==-1) purl = purl + '?' + gkey; | |||
| else purl = purl + '&' + gkey; | |||
| } | |||
| DedeXHTTP.open("GET", purl, false); | |||
| this.SendHead(); | |||
| DedeXHTTP.send(null); | |||
| //firefox中直接检测XHTTP状态 | |||
| this.BarrageStat(); | |||
| }; | |||
| //用Post方式发送数据 | |||
| this.SendPost2 = function(purl) { | |||
| var pdata = ""; | |||
| var i=0; | |||
| this.state = 0; | |||
| DedeXHTTP.open("POST", purl, false); | |||
| this.SendHead(); | |||
| //post数据 | |||
| if(this.keyCount!=-1) | |||
| { | |||
| for(;i<=this.keyCount;i++) | |||
| { | |||
| if(pdata=="") pdata = this.keys[i]+'='+this.values[i]; | |||
| else pdata += "&"+this.keys[i]+'='+this.values[i]; | |||
| } | |||
| } | |||
| DedeXHTTP.send(pdata); | |||
| //firefox中直接检测XHTTP状态 | |||
| this.BarrageStat(); | |||
| }; | |||
| } // End Class DedeAjax | |||
| //初始化xmldom | |||
| function InitXDom() { | |||
| if(DedeXDOM!=null) return; | |||
| var obj = null; | |||
| // Gecko、Mozilla、Firefox | |||
| if (typeof(DOMParser) != "undefined") { | |||
| var parser = new DOMParser(); | |||
| obj = parser.parseFromString(xmlText, "text/xml"); | |||
| } | |||
| // IE | |||
| else { | |||
| try { obj = new ActiveXObject("MSXML2.DOMDocument");} catch (e) { } | |||
| if (obj == null) try { obj = new ActiveXObject("Microsoft.XMLDOM"); } catch (e) { } | |||
| } | |||
| DedeXDOM = obj; | |||
| }; | |||
| //读写cookie函数 | |||
| function GetCookie(c_name) | |||
| { | |||
| if (document.cookie.length > 0) | |||
| { | |||
| c_start = document.cookie.indexOf(c_name + "=") | |||
| if (c_start != -1) | |||
| { | |||
| c_start = c_start + c_name.length + 1; | |||
| c_end = document.cookie.indexOf(";",c_start); | |||
| if (c_end == -1) | |||
| { | |||
| c_end = document.cookie.length; | |||
| } | |||
| return unescape(document.cookie.substring(c_start,c_end)); | |||
| } | |||
| } | |||
| return null | |||
| } | |||
| function SetCookie(c_name,value,expiredays) | |||
| { | |||
| var exdate = new Date(); | |||
| exdate.setDate(exdate.getDate() + expiredays); | |||
| document.cookie = c_name + "=" +escape(value) + ((expiredays == null) ? "" : ";expires=" + exdate.toGMTString()); //使设置的有效时间正确。增加toGMTString() | |||
| } | |||
| --> | |||
| @@ -1,8 +1,6 @@ | |||
| <?php | |||
| if (!defined('DEDEINC')) exit('dedebiz'); | |||
| //为了兼容旧版本文件,这里将函数直接封装到archive小助手中 | |||
| //所以这里仅做一个文件引入映射,今后的开发,如果遇到此类函数 | |||
| //在开发过程中直接使用helper('archive');即可 | |||
| helper('archive'); | |||
| helper('archive'); | |||
| @@ -35,4 +35,4 @@ function __autoload($classname) | |||
| die (); | |||
| } | |||
| } | |||
| } | |||
| } | |||
| @@ -36,4 +36,4 @@ function dede_autoloader($classname) | |||
| } | |||
| } | |||
| } | |||
| spl_autoload_register('dede_autoloader'); | |||
| spl_autoload_register('dede_autoloader'); | |||
| @@ -10,7 +10,6 @@ if (!defined('DEDEINC')) exit('dedebiz'); | |||
| */ | |||
| require_once(DEDEINC."/dedetag.class.php"); | |||
| require_once(DEDEINC."/channelunit.func.php"); | |||
| /*---------------------------------- | |||
| function C____ChannelUnit(); | |||
| -----------------------------------*/ | |||
| @@ -23,7 +22,6 @@ class ChannelUnit | |||
| var $ArcID; | |||
| var $dsql; | |||
| var $SplitPageField; | |||
| //php5构造函数 | |||
| function __construct($cid, $aid = 0) | |||
| { | |||
| @@ -71,12 +69,10 @@ class ChannelUnit | |||
| } | |||
| $dtp->Clear(); | |||
| } | |||
| function ChannelUnit($cid, $aid = 0) | |||
| { | |||
| $this->__construct($cid, $aid); | |||
| } | |||
| /** | |||
| * 设置档案ID | |||
| * | |||
| @@ -88,7 +84,6 @@ class ChannelUnit | |||
| { | |||
| $this->ArcID = $aid; | |||
| } | |||
| /** | |||
| * 处理某个字段的值 | |||
| * | |||
| @@ -105,7 +100,6 @@ class ChannelUnit | |||
| if ($fvalue == '') { | |||
| if ($ftype != 'checkbox') $fvalue = $this->ChannelFields[$fname]['default']; | |||
| } | |||
| if ($ftype == 'text') { | |||
| $fvalue = HtmlReplace($fvalue); | |||
| } else if ($ftype == 'textdata') { | |||
| @@ -130,7 +124,6 @@ class ChannelUnit | |||
| } | |||
| return $fvalue; | |||
| } | |||
| /** | |||
| * 获取缩略图链接 | |||
| * | |||
| @@ -147,7 +140,6 @@ class ChannelUnit | |||
| if (empty($GLOBALS["stNowPage"])) $NowPage = 1; | |||
| else $NowPage = intval($GLOBALS["stNowPage"]); | |||
| } | |||
| $revalue = ""; | |||
| $dtp = new DedeTagParse(); | |||
| $dtp->LoadSource($fvalue); | |||
| @@ -177,7 +169,6 @@ class ChannelUnit | |||
| $photoid = 1; | |||
| $images = array(); | |||
| $TotalPhoto = sizeof($dtp->CTags); | |||
| foreach ($dtp->CTags as $ctag) { | |||
| if ($ctag->GetName() == "img") { | |||
| $iw = $ctag->GetAtt('width'); | |||
| @@ -205,7 +196,6 @@ class ChannelUnit | |||
| unset($images); | |||
| return $revalue; | |||
| } | |||
| //关闭所占用的资源 | |||
| function Close() | |||
| { | |||
| @@ -11,7 +11,6 @@ if (!defined('DEDEINC')) exit('dedebiz'); | |||
| */ | |||
| if (!isset($cfg_mainsite)) extract($GLOBALS, EXTR_SKIP); | |||
| global $PubFields, $pTypeArrays, $idArrary, $envs, $v1, $v2; | |||
| $pTypeArrays = $idArrary = $PubFields = $envs = array(); | |||
| $PubFields['phpurl'] = $cfg_phpurl; | |||
| $PubFields['indexurl'] = $cfg_mainsite.$cfg_indexurl; | |||
| @@ -25,5 +24,4 @@ $envs['reid'] = 0; | |||
| $envs['aid'] = 0; | |||
| $envs['keyword'] = ''; | |||
| $envs['idlist'] = ''; | |||
| helper('channelunit'); | |||
| helper('channelunit'); | |||
| @@ -10,4 +10,4 @@ if (!defined('DEDEINC')) exit('dedebiz'); | |||
| //------------------------------------------------------------------------ | |||
| //字符编码转换的小助手 | |||
| //这里仅做一个映射 | |||
| helper("charset"); | |||
| helper("charset"); | |||
| @@ -18,7 +18,7 @@ define('DEDEINC', str_replace("\\", '/', dirname(__FILE__))); | |||
| define('DEDEROOT', str_replace("\\", '/', substr(DEDEINC, 0, -6))); // 站点根目录 | |||
| define('DEDEDATA', substr(DEDEINC, 0, -6).'data'); | |||
| define('DEDEMEMBER', DEDEROOT.'/user'); | |||
| define('DEDETEMPLATE', DEDEROOT.'/templets'); | |||
| define('DEDETEMPLATE', DEDEROOT.'/theme'); | |||
| define('DEDEBIZURL', "https://www.dedebiz.com");//Dede商业支持 | |||
| define('DEDEVER', 6);//当前系统大版本 | |||
| define('DEDEPUB', '-----BEGIN PUBLIC KEY----- | |||
| @@ -159,9 +159,9 @@ if ($cfg_multi_site == 'Y') { | |||
| $cfg_mainsite = ''; | |||
| } | |||
| //模板的存放目录 | |||
| $cfg_templets_dir = $cfg_cmspath.'/templets'; | |||
| $cfg_templets_dir = $cfg_cmspath.'/theme'; | |||
| $cfg_templeturl = $cfg_mainsite.$cfg_templets_dir; | |||
| $cfg_templets_skin = empty($cfg_df_style) ? $cfg_mainsite.$cfg_templets_dir."/default" : $cfg_mainsite.$cfg_templets_dir."/$cfg_df_style"; | |||
| $cfg_templets_skin = empty($cfg_df_style) ? $cfg_mainsite.$cfg_templets_dir."/muban" : $cfg_mainsite.$cfg_templets_dir."/$cfg_df_style"; | |||
| //cms安装目录的网址 | |||
| $cfg_cmsurl = $cfg_mainsite.$cfg_cmspath; | |||
| //插件目录,这个目录是用于存放计数器、投票、评论等程序的必要动态程序 | |||
| @@ -8,7 +8,6 @@ if (!defined('DEDEINC')) exit('dedebiz'); | |||
| * @license https://www.dedebiz.com/license | |||
| * @link https://www.dedebiz.com | |||
| */ | |||
| /** | |||
| * 获得一个附加表单(发布时用) | |||
| * | |||
| @@ -28,11 +28,10 @@ if (file_exists(DEDEINC.'/code/datalist.'.$codefile.'.inc')) { | |||
| $lang_next_page = '下页'; | |||
| $lang_index_page = '首页'; | |||
| $lang_end_page = '末页'; | |||
| $lang_record_number = '条记录'; | |||
| $lang_record_number = '篇'; | |||
| $lang_page = '页'; | |||
| $lang_total = '共'; | |||
| } | |||
| /** | |||
| * DataListCP | |||
| * | |||
| @@ -50,7 +49,6 @@ class DataListCP | |||
| var $sourceSql; | |||
| var $isQuery; | |||
| var $queryTime; | |||
| /** | |||
| * 用指定的文档ID进行初始化 | |||
| * | |||
| @@ -69,7 +67,6 @@ class DataListCP | |||
| } else { | |||
| $dsql = $GLOBALS['dsqlitete']; | |||
| } | |||
| $this->sourceSql = ''; | |||
| $this->pageSize = 25; | |||
| $this->queryTime = 0; | |||
| @@ -88,7 +85,6 @@ class DataListCP | |||
| $this->tpl->LoadTemplate($tplfile); | |||
| } | |||
| } | |||
| /** | |||
| * 兼容PHP4版本 | |||
| * | |||
| @@ -100,13 +96,11 @@ class DataListCP | |||
| { | |||
| $this->__construct($tplfile); | |||
| } | |||
| //设置SQL语句 | |||
| function SetSource($sql) | |||
| { | |||
| $this->sourceSql = $sql; | |||
| } | |||
| //设置模板 | |||
| //如果想要使用模板中指定的pagesize,必须在调用模板后才调用 SetSource($sql) | |||
| function SetTemplate($tplfile) | |||
| @@ -117,7 +111,6 @@ class DataListCP | |||
| { | |||
| $this->tpl->LoadTemplate($tplfile); | |||
| } | |||
| /** | |||
| * 对config参数及get参数等进行预处理 | |||
| * | |||
| @@ -135,7 +128,6 @@ class DataListCP | |||
| } | |||
| $this->pageNO = $pageno; | |||
| $this->totalResult = $totalresult; | |||
| if (isset($this->tpl->tpCfgs['pagesize'])) { | |||
| $this->pageSize = $this->tpl->tpCfgs['pagesize']; | |||
| } | |||
| @@ -152,13 +144,11 @@ class DataListCP | |||
| $this->sourceSql .= " LIMIT ".(($this->pageNO - 1) * $this->pageSize).",".$this->pageSize; | |||
| } | |||
| } | |||
| //设置网址的Get参数键值 | |||
| function SetParameter($key, $value) | |||
| { | |||
| $this->getValues[$key] = $value; | |||
| } | |||
| //设置/获取文档相关的各种变量 | |||
| function SetVar($k, $v) | |||
| { | |||
| @@ -167,13 +157,11 @@ class DataListCP | |||
| $_vars[$k] = $v; | |||
| } | |||
| } | |||
| function GetVar($k) | |||
| { | |||
| global $_vars; | |||
| return isset($_vars[$k]) ? $_vars[$k] : ''; | |||
| } | |||
| function XSSClean($val) | |||
| { | |||
| if (is_array($val)) { | |||
| @@ -184,7 +172,6 @@ class DataListCP | |||
| } | |||
| return $this->RemoveXss($val); | |||
| } | |||
| function RemoveXss($val) | |||
| { | |||
| global $cfg_soft_lang; | |||
| @@ -198,18 +185,15 @@ class DataListCP | |||
| $val = preg_replace('/(&#[xX]0{0,8}'.dechex(ord($search[$i])).';?)/i', $search[$i], $val); //with a ; | |||
| $val = preg_replace('/(�{0,8}'.ord($search[$i]).';?)/', $search[$i], $val); //with a ; | |||
| } | |||
| $val = str_replace("`", "‘", $val); | |||
| $val = str_replace("'", "‘", $val); | |||
| $val = str_replace("\"", "“", $val); | |||
| $val = str_replace(",", ",", $val); | |||
| $val = str_replace("(", "(", $val); | |||
| $val = str_replace(")", ")", $val); | |||
| $ra1 = array('javascript', 'vbscript', 'expression', 'applet', 'meta', 'xml', 'blink', 'link', 'style', 'script', 'embed', 'object', 'iframe', 'frame', 'frameset', 'ilayer', 'layer', 'bgsound', 'title', 'base'); | |||
| $ra2 = array('onabort', 'onactivate', 'onafterprint', 'onafterupdate', 'onbeforeactivate', 'onbeforecopy', 'onbeforecut', 'onbeforedeactivate', 'onbeforeeditfocus', 'onbeforepaste', 'onbeforeprint', 'onbeforeunload', 'onbeforeupdate', 'onblur', 'onbounce', 'oncellchange', 'onchange', 'onclick', 'oncontextmenu', 'oncontrolselect', 'oncopy', 'oncut', 'ondataavailable', 'ondatasetchanged', 'ondatasetcomplete', 'ondblclick', 'ondeactivate', 'ondrag', 'ondragend', 'ondragenter', 'ondragleave', 'ondragover', 'ondragstart', 'ondrop', 'onerror', 'onerrorupdate', 'onfilterchange', 'onfinish', 'onfocus', 'onfocusin', 'onfocusout', 'onhelp', 'onkeydown', 'onkeypress', 'onkeyup', 'onlayoutcomplete', 'onload', 'onlosecapture', 'onmousedown', 'onmouseenter', 'onmouseleave', 'onmousemove', 'onmouseout', 'onmouseover', 'onmouseup', 'onmousewheel', 'onmove', 'onmoveend', 'onmovestart', 'onpaste', 'onpropertychange', 'onreadystatechange', 'onreset', 'onresize', 'onresizeend', 'onresizestart', 'onrowenter', 'onrowexit', 'onrowsdelete', 'onrowsinserted', 'onscroll', 'onselect', 'onselectionchange', 'onselectstart', 'onstart', 'onstop', 'onsubmit', 'onunload'); | |||
| $ra = array_merge($ra1, $ra2); | |||
| $found = true; | |||
| while ($found == true) { | |||
| $val_before = $val; | |||
| @@ -236,7 +220,6 @@ class DataListCP | |||
| if ($cfg_soft_lang == 'gb2312') $val = utf82gb($val); | |||
| return $val; | |||
| } | |||
| //获取当前页数据列表 | |||
| function GetArcList($atts, $refObj = '', $fields = array()) | |||
| { | |||
| @@ -255,7 +238,6 @@ class DataListCP | |||
| $this->queryTime = (Exectime() - $t1); | |||
| return $rsArray; | |||
| } | |||
| //获取分页导航列表 | |||
| function GetPageList($atts, $refObj = '', $fields = array()) | |||
| { | |||
| @@ -271,7 +253,6 @@ class DataListCP | |||
| $atts['listitem'] = "info,index,end,pre,next,pageno"; | |||
| } | |||
| $totalpage = ceil($this->totalResult / $this->pageSize); | |||
| //echo " {$totalpage}=={$this->totalResult}=={$this->pageSize}"; | |||
| //无结果或只有一页的情况 | |||
| if ($totalpage <= 1 && $this->totalResult > 0) { | |||
| @@ -292,7 +273,6 @@ class DataListCP | |||
| } | |||
| } | |||
| $purl .= "?".$geturl; | |||
| //获得上一页和下一页的链接 | |||
| if ($this->pageNO != 1) { | |||
| $prepage .= "<li class='page-item'><a class='page-link' href='".$purl."pageno=$prepagenum'>$lang_pre_page</a></li> \n"; | |||
| @@ -306,7 +286,6 @@ class DataListCP | |||
| } else { | |||
| $endpage = " <li class='page-item d-none d-sm-block disabled'><span class=\"page-link\">$lang_end_page</span></li> \n"; | |||
| } | |||
| //获得数字链接 | |||
| $listdd = ""; | |||
| $total_list = $atts['listsize'] * 2 + 1; | |||
| @@ -325,9 +304,7 @@ class DataListCP | |||
| for ($j; $j <= $total_list; $j++) { | |||
| $listdd .= $j == $this->pageNO ? "<li class='page-item'><span class='page-link'>$j</span></li>\r\n" : "<li class='page-item'><a class='page-link' href='".$purl."pageno=$j'>".$j."</a></li>\n"; | |||
| } | |||
| $plist = "<ul class='pagination justify-content-center'>\n"; | |||
| //info,index,end,pre,next,pageno,form | |||
| if (preg_match("#info#i", $atts['listitem'])) { | |||
| $plist .= $infos; | |||
| @@ -358,7 +335,6 @@ class DataListCP | |||
| $plist .= "</ul>\n"; | |||
| return $plist; | |||
| } | |||
| //获得当前网址 | |||
| function GetCurUrl() | |||
| { | |||
| @@ -371,25 +347,21 @@ class DataListCP | |||
| } | |||
| return $nowurl; | |||
| } | |||
| //关闭 | |||
| function Close() | |||
| { | |||
| } | |||
| //显示数据 | |||
| function Display() | |||
| { | |||
| $this->PreLoad(); | |||
| //在PHP4中,对象引用必须放在display之前,放在其它位置中无效 | |||
| $this->tpl->SetObject($this); | |||
| $this->tpl->Display(); | |||
| } | |||
| //保存为HTML | |||
| function SaveTo($filename) | |||
| { | |||
| $this->tpl->SaveTo($filename); | |||
| } | |||
| } | |||
| } | |||
| @@ -8,7 +8,6 @@ | |||
| * @license https://www.dedebiz.com/license | |||
| * @link https://www.dedebiz.com | |||
| */ | |||
| //------------------------------------------------------------------------ | |||
| /** | |||
| * 属性的数据描述 | |||
| * function c____DedeAtt(); | |||
| @@ -21,7 +20,6 @@ class DedeAtt | |||
| { | |||
| var $Count = -1; | |||
| var $Items = array(); //属性元素的集合 | |||
| /** | |||
| * //获得某个属性 | |||
| * | |||
| @@ -40,13 +38,11 @@ class DedeAtt | |||
| return ""; | |||
| } | |||
| } | |||
| //同上 | |||
| function GetAttribute($str) | |||
| { | |||
| return $this->GetAtt($str); | |||
| } | |||
| /** | |||
| * 判断属性是否存在 | |||
| * | |||
| @@ -58,7 +54,6 @@ class DedeAtt | |||
| { | |||
| return isset($this->Items[$str]) ? TRUE : FALSE; | |||
| } | |||
| /** | |||
| * 获得标记名称 | |||
| * | |||
| @@ -69,7 +64,6 @@ class DedeAtt | |||
| { | |||
| return $this->GetAtt("tagname"); | |||
| } | |||
| /** | |||
| * 获得属性个数 | |||
| * | |||
| @@ -80,8 +74,7 @@ class DedeAtt | |||
| { | |||
| return $this->Count + 1; | |||
| } | |||
| } //End DedeAtt | |||
| }//End DedeAtt | |||
| /** | |||
| * 属性解析器 | |||
| * function c____DedeAttParse(); | |||
| @@ -96,7 +89,6 @@ class DedeAttParse | |||
| var $SourceMaxSize = 1024; | |||
| var $CAtt; //属性的数据描述类 | |||
| var $CharToLow = TRUE; | |||
| /** | |||
| * 设置属性解析器源字符串 | |||
| * | |||
| @@ -114,7 +106,6 @@ class DedeAttParse | |||
| $this->ParseAtt(); | |||
| } | |||
| } | |||
| /** | |||
| * 解析属性(私有成员,仅给SetSource调用) | |||
| * | |||
| @@ -130,7 +121,6 @@ class DedeAttParse | |||
| $ddtag = ""; | |||
| $notAttribute = TRUE; | |||
| $strLen = strlen($this->SourceString); | |||
| //这里是获得Tag的名称,可视情况是否需要 | |||
| //如果不在这个里解析,则在解析整个Tag时解析 | |||
| //属性中不应该存在tagname这个名称 | |||
| @@ -150,13 +140,11 @@ class DedeAttParse | |||
| $tmpvalue .= $d; | |||
| } | |||
| } | |||
| //不存在属性列表的情况 | |||
| if ($notAttribute) { | |||
| $this->CAtt->Count++; | |||
| $this->CAtt->Items["tagname"] = ($this->CharToLow ? strtolower(trim($tmpvalue)) : trim($tmpvalue)); | |||
| } | |||
| //如果字符串含有属性值,遍历源字符串,并获得各属性 | |||
| if (!$notAttribute) { | |||
| for ($i; $i < $strLen; $i++) { | |||
| @@ -209,6 +197,5 @@ class DedeAttParse | |||
| } //完成属性解析 | |||
| } //for | |||
| } //has Attribute | |||
| }//End DedeAttParse | |||
| @@ -12,7 +12,6 @@ if (!defined('DEDEINC')) exit('dedebiz'); | |||
| require_once(DEDEINC."/libraries/dedehttpdown.class.php"); | |||
| require_once(DEDEINC."/dedetag.class.php"); | |||
| require_once(DEDEINC."/charset.func.php"); | |||
| /** | |||
| * 下载图片 | |||
| * | |||
| @@ -50,7 +49,6 @@ function DownImageKeep($gurl, $rfurl, $filename, $gcookie = "", $JumpCount = 0, | |||
| $m_fp = fsockopen($ghost, 80, $errno, $errstr, 10); | |||
| fwrite($m_fp, $sessionQuery); | |||
| $lnum = 0; | |||
| //获取详细应答头 | |||
| $m_httphead = array(); | |||
| $httpstas = explode(" ", fgets($m_fp, 256)); | |||
| @@ -80,7 +78,6 @@ function DownImageKeep($gurl, $rfurl, $filename, $gcookie = "", $JumpCount = 0, | |||
| $m_httphead[strtolower($hkey)] = trim($hvalue); | |||
| } | |||
| } | |||
| //分析返回记录 | |||
| if (preg_match("/^3/", $m_httphead["http-state"])) { | |||
| if (isset($m_httphead["location"]) && $JumpCount < 3) { | |||
| @@ -97,7 +94,6 @@ function DownImageKeep($gurl, $rfurl, $filename, $gcookie = "", $JumpCount = 0, | |||
| return FALSE; | |||
| } | |||
| $contentLength = $m_httphead['content-length']; | |||
| //保存文件 | |||
| $fp = fopen($filename, "w") or die("写入文件:{$filename} 失败"); | |||
| $i = 0; | |||
| @@ -106,12 +102,10 @@ function DownImageKeep($gurl, $rfurl, $filename, $gcookie = "", $JumpCount = 0, | |||
| while (!feof($m_fp)) { | |||
| $okdata .= fgetc($m_fp); | |||
| $i++; | |||
| //超时结束 | |||
| if (time() - $starttime > $maxtime) { | |||
| break; | |||
| } | |||
| //到达指定大小结束 | |||
| if ($i >= $contentLength) { | |||
| break; | |||
| @@ -129,7 +123,6 @@ function DownImageKeep($gurl, $rfurl, $filename, $gcookie = "", $JumpCount = 0, | |||
| fclose($m_fp); | |||
| return TRUE; | |||
| } | |||
| /** | |||
| * 获得某页面返回的Cookie信息 | |||
| * | |||
| @@ -162,7 +155,6 @@ function RefurlCookie($gurl) | |||
| $m_fp = fsockopen($ghost, 80, $errno, $errstr, 10) or die($ghost.'<br>'); | |||
| fwrite($m_fp, $sessionQuery); | |||
| $lnum = 0; | |||
| //获取详细应答头 | |||
| $gcookie = ""; | |||
| while (!feof($m_fp)) { | |||
| @@ -179,7 +171,6 @@ function RefurlCookie($gurl) | |||
| fclose($m_fp); | |||
| return $gcookie; | |||
| } | |||
| /** | |||
| * 获得网址的host和query部份 | |||
| * | |||
| @@ -194,7 +185,6 @@ function GetHostInfo($gurl) | |||
| $garr['query'] = "/".preg_replace("/^([^\/]*)\//i", "", $gurl); | |||
| return $garr; | |||
| } | |||
| /** | |||
| * HTML里的图片转DEDE格式 | |||
| * | |||
| @@ -225,7 +215,6 @@ function TurnImageTag(&$body) | |||
| $ttx = "\r\n{dede:pagestyle maxwidth='{$cfg_album_width}' ddmaxwidth='{$cfg_ddimg_width}' row='3' col='3' value='2'/}\r\n{dede:comments}图集类型会采集时生成此配置是正常的,不过如果后面没有跟着img标记则表示规则无效{/dede:comments}\r\n".$ttx; | |||
| return $ttx; | |||
| } | |||
| /** | |||
| * HTML里的网址格式转换 | |||
| * | |||
| @@ -249,7 +238,6 @@ function TurnLinkTag(&$body) | |||
| } | |||
| return $ttx; | |||
| } | |||
| /** | |||
| * 替换XML的CDATA | |||
| * | |||
| @@ -263,7 +251,6 @@ function RpCdata($str) | |||
| $str = str_replace(']]>', '', $str); | |||
| return $str; | |||
| } | |||
| /** | |||
| * 分析RSS里的链接 | |||
| * | |||
| @@ -277,7 +264,6 @@ function GetRssLinks($rssurl) | |||
| $dhd = new DedeHttpDown(); | |||
| $dhd->OpenUrl($rssurl); | |||
| $rsshtml = $dhd->GetHtml(); | |||
| //分析编码 | |||
| preg_match("/encoding=[\"']([^\"']*)[\"']/is", $rsshtml, $infos); | |||
| if (isset($infos[1])) { | |||
| @@ -321,7 +307,6 @@ function GetRssLinks($rssurl) | |||
| } | |||
| return $rsarr; | |||
| } | |||
| /** | |||
| * 从RSS摘要获取图片信息 | |||
| * | |||
| @@ -344,7 +329,6 @@ function GetddImgFromRss($descriptions, $refurl) | |||
| return ''; | |||
| } | |||
| } | |||
| /** | |||
| * 补全网址 | |||
| * | |||
| @@ -361,7 +345,6 @@ function FillUrl($refurl, $surl) | |||
| $surl = trim($surl); | |||
| $urls = @parse_url($refurl); | |||
| $basehost = ((!isset($urls['port']) || $urls['port'] == '80') ? $urls['host'] : $urls['host'].':'.$urls['port']); | |||
| //$basepath = $basehost.(!isset($urls['path']) ? '' : '/'.$urls['path']); | |||
| //由于直接获得的path在处理 http://xxxx/nnn/aaa?fdsafd 这种情况时会有错误,因此用其它方式处理 | |||
| $basepath = $basehost; | |||
| @@ -380,7 +363,6 @@ function FillUrl($refurl, $surl) | |||
| if ($pos > 0) { | |||
| $surl = substr($surl, 0, $pos); | |||
| } | |||
| //用 '/' 表示网站根的网址 | |||
| if ($surl[0] == '/') { | |||
| $okurl = $basehost.$surl; | |||
| @@ -405,7 +387,6 @@ function FillUrl($refurl, $surl) | |||
| $okurl = 'http://'.preg_replace("/\/{1,}/", '/', $okurl); | |||
| return $okurl; | |||
| } | |||
| /** | |||
| * 从匹配规则中获取列表网址 | |||
| * | |||
| @@ -422,7 +403,6 @@ function FillUrl($refurl, $surl) | |||
| function GetUrlFromListRule($regxurl = '', $handurl = '', $startid = 0, $endid = 0, $addv = 1, $usemore = 0, $batchrule = '') | |||
| { | |||
| global $dsql, $islisten; | |||
| $lists = array(); | |||
| $n = 0; | |||
| $islisten = (empty($islisten) ? 0 : $islisten); | |||
| @@ -450,7 +430,6 @@ function GetUrlFromListRule($regxurl = '', $handurl = '', $startid = 0, $endid = | |||
| if ($addv <= 0) { | |||
| $addv = 1; | |||
| } | |||
| //没指定多栏目匹配规则 | |||
| if ($usemore == 0) { | |||
| while ($startid <= $endid) { | |||
| @@ -463,7 +442,6 @@ function GetUrlFromListRule($regxurl = '', $handurl = '', $startid = 0, $endid = | |||
| } | |||
| } | |||
| } | |||
| //匹配多个栏目 | |||
| //规则表达式 [(#)=>(#)匹配的网址; (*)=>(*)的范围,如:1-20; typeid=>栏目id; addurl=>附加的网址(用|分开多个)] | |||
| else { | |||
| @@ -495,7 +473,6 @@ function GetUrlFromListRule($regxurl = '', $handurl = '', $startid = 0, $endid = | |||
| list($startid, $endid) = explode('-', $v); | |||
| } | |||
| } | |||
| //如果栏目用栏目名称 | |||
| if (preg_match('/[^0-9]/', $typeid)) { | |||
| $arr = $dsql->GetOne("SELECT id FROM `#@__arctype` WHERE typename LIKE '$typeid' "); | |||
| @@ -505,7 +482,6 @@ function GetUrlFromListRule($regxurl = '', $handurl = '', $startid = 0, $endid = | |||
| $typeid = 0; | |||
| } | |||
| } | |||
| //附加网址优先 | |||
| $mjj = 0; | |||
| if (isset($addurls[0])) { | |||
| @@ -523,7 +499,6 @@ function GetUrlFromListRule($regxurl = '', $handurl = '', $startid = 0, $endid = | |||
| } | |||
| } | |||
| } | |||
| //如果为非监听模式或监听模式没手工指定的附加网址 | |||
| if ($islisten != 1 || $mjj == 0) { | |||
| //匹配规则里的网址,注:(#)的网址是是允许使用(*)的 | |||
| @@ -543,10 +518,7 @@ function GetUrlFromListRule($regxurl = '', $handurl = '', $startid = 0, $endid = | |||
| } | |||
| } | |||
| } //End 匹配多栏目 | |||
| } //End使用规则匹配的情况 | |||
| } | |||
| return $lists; | |||
| }//End | |||
| @@ -1,7 +1,7 @@ | |||
| <?php | |||
| if (!defined('DEDEINC')) exit('dedebiz'); | |||
| /** | |||
| * Dede织梦模板类 | |||
| * DedeBIZ模板类 | |||
| * | |||
| * @version $Id: dedetag.class.php 1 10:33 2010年7月6日Z tianya $ | |||
| * @package DedeBIZ.Libraries | |||
| @@ -27,7 +27,6 @@ class DedeTag | |||
| var $CAttribute = null; //标记属性描述,即是class DedeAttribute | |||
| var $TagValue = ""; //标记的值 | |||
| var $TagID = 0; | |||
| /** | |||
| * 获取标记的名称和值 | |||
| * | |||
| @@ -38,7 +37,6 @@ class DedeTag | |||
| { | |||
| return strtolower($this->TagName); | |||
| } | |||
| /** | |||
| * 获取值 | |||
| * | |||
| @@ -49,40 +47,33 @@ class DedeTag | |||
| { | |||
| return $this->TagValue; | |||
| } | |||
| //下面两个成员函数仅是为了兼容旧版 | |||
| function GetTagName() | |||
| { | |||
| return strtolower($this->TagName); | |||
| } | |||
| function GetTagValue() | |||
| { | |||
| return $this->TagValue; | |||
| } | |||
| //获取标记的指定属性 | |||
| function IsAttribute($str) | |||
| { | |||
| return $this->CAttribute->IsAttribute($str); | |||
| } | |||
| function GetAttribute($str) | |||
| { | |||
| return $this->CAttribute->GetAtt($str); | |||
| } | |||
| function GetAtt($str) | |||
| { | |||
| return $this->CAttribute->GetAtt($str); | |||
| } | |||
| function GetInnerText() | |||
| { | |||
| return $this->InnerText; | |||
| } | |||
| } | |||
| /** | |||
| * DedeTagParse Dede织梦模板类 | |||
| * function c____DedeTagParse(); | |||
| @@ -106,7 +97,6 @@ class DedeTagParse | |||
| var $Count = -1; //$Tags标记个数 | |||
| var $refObj = ''; //引用当前模板类的对象 | |||
| var $taghashfile = ''; | |||
| function __construct() | |||
| { | |||
| if (!isset($GLOBALS['cfg_tplcache'])) { | |||
| @@ -131,12 +121,10 @@ class DedeTagParse | |||
| $this->TempMkTime = 0; | |||
| $this->CacheFile = ''; | |||
| } | |||
| function DedeTagParse() | |||
| { | |||
| $this->__construct(); | |||
| } | |||
| /** | |||
| * 设置标记的命名空间,默认为dede | |||
| * | |||
| @@ -152,7 +140,6 @@ class DedeTagParse | |||
| $this->TagStartWord = $s; | |||
| $this->TagEndWord = $e; | |||
| } | |||
| /** | |||
| * 重置成员变量或Clear | |||
| * | |||
| @@ -165,7 +152,6 @@ class DedeTagParse | |||
| $this->CTags = array(); | |||
| $this->Count = -1; | |||
| } | |||
| /** | |||
| * 强制引用 | |||
| * | |||
| @@ -177,19 +163,14 @@ class DedeTagParse | |||
| { | |||
| $this->refObj = $refObj; | |||
| } | |||
| function GetCount() | |||
| { | |||
| return $this->Count + 1; | |||
| } | |||
| function Clear() | |||
| { | |||
| $this->SetDefault(); | |||
| } | |||
| //------------------------------------------------------------------------ | |||
| /** | |||
| * CheckDisabledFunctions | |||
| * | |||
| @@ -218,7 +199,6 @@ class DedeTagParse | |||
| } | |||
| return TRUE; | |||
| } | |||
| /** | |||
| * 检测模板缓存 | |||
| * | |||
| @@ -242,7 +222,6 @@ class DedeTagParse | |||
| if (!file_exists($ckfullfile) || !file_exists($ckfullfile_t)) { | |||
| return FALSE; | |||
| } | |||
| //检测模板最后更新时间 | |||
| $fp = fopen($ckfullfile_t, 'r'); | |||
| $time_info = trim(fgets($fp, 64)); | |||
| @@ -250,11 +229,9 @@ class DedeTagParse | |||
| if ($time_info != $this->TempMkTime) { | |||
| return FALSE; | |||
| } | |||
| //引入缓冲数组 | |||
| include($this->CacheFile); | |||
| $errmsg = ''; | |||
| //把缓冲数组内容读入类 | |||
| if (isset($z) && is_array($z)) { | |||
| foreach ($z as $k => $v) { | |||
| @@ -285,7 +262,6 @@ class DedeTagParse | |||
| } | |||
| return TRUE; | |||
| } | |||
| /** | |||
| * 写入缓存 | |||
| * | |||
| @@ -337,7 +313,6 @@ class DedeTagParse | |||
| fclose($fp); | |||
| } | |||
| } | |||
| /** | |||
| * 载入模板文件 | |||
| * | |||
| @@ -364,19 +339,16 @@ class DedeTagParse | |||
| } | |||
| } | |||
| } | |||
| //仅用于兼容旧版本 | |||
| function LoadTemplet($filename) | |||
| { | |||
| $this->LoadTemplate($filename); | |||
| } | |||
| //仅用于兼容旧版本 | |||
| function LoadFile($filename) | |||
| { | |||
| $this->LoadTemplate($filename); | |||
| } | |||
| /** | |||
| * 载入模板字符串 | |||
| * | |||
| @@ -386,12 +358,6 @@ class DedeTagParse | |||
| */ | |||
| function LoadSource($str) | |||
| { | |||
| /* | |||
| $this->SetDefault(); | |||
| $this->SourceString = $str; | |||
| $this->IsCache = FALSE; | |||
| $this->ParseTemplet(); | |||
| */ | |||
| //优化模板字符串存取读取方式 | |||
| $this->taghashfile = $filename = DEDEDATA.'/tplcache/'.md5($str).'.inc'; | |||
| if (!is_file($filename)) { | |||
| @@ -399,12 +365,10 @@ class DedeTagParse | |||
| } | |||
| $this->LoadTemplate($filename); | |||
| } | |||
| function LoadString($str) | |||
| { | |||
| $this->LoadSource($str); | |||
| } | |||
| /** | |||
| * 获得指定名称的Tag的ID(如果有多个同名的Tag,则取没有被取代为内容的第一个Tag) | |||
| * | |||
| @@ -428,7 +392,6 @@ class DedeTagParse | |||
| } | |||
| return -1; | |||
| } | |||
| /** | |||
| * 获得指定名称的CTag数据类(如果有多个同名的Tag,则取没有被分配内容的第一个Tag) | |||
| * | |||
| @@ -452,7 +415,6 @@ class DedeTagParse | |||
| } | |||
| return ''; | |||
| } | |||
| /** | |||
| * 通过名称获取标记 | |||
| * | |||
| @@ -464,7 +426,6 @@ class DedeTagParse | |||
| { | |||
| return $this->GetTag($str); | |||
| } | |||
| /** | |||
| * 获得指定ID的CTag数据类 | |||
| * | |||
| @@ -480,7 +441,6 @@ class DedeTagParse | |||
| return ''; | |||
| } | |||
| } | |||
| /** | |||
| * 给_vars数组传递一个元素 | |||
| * | |||
| @@ -496,7 +456,6 @@ class DedeTagParse | |||
| } | |||
| $_sys_globals[$vname] = $vvalue; | |||
| } | |||
| /** | |||
| * 分配指定ID的标记的值 | |||
| * | |||
| @@ -517,7 +476,6 @@ class DedeTagParse | |||
| } | |||
| } | |||
| } | |||
| /** | |||
| * 分配指定名称的标记的值,如果标记包含属性,请不要用此函数 | |||
| * | |||
| @@ -534,7 +492,6 @@ class DedeTagParse | |||
| } | |||
| } | |||
| } | |||
| /** | |||
| * 处理特殊标记 | |||
| * | |||
| @@ -547,7 +504,6 @@ class DedeTagParse | |||
| for ($i = 0; $i <= $this->Count; $i++) { | |||
| $CTag = $this->CTags[$i]; | |||
| $str = ''; | |||
| //获取一个外部变量 | |||
| if ($CTag->TagName == 'global') { | |||
| $str = $this->GetGlobals($CTag->GetAtt('name')); | |||
| @@ -558,7 +514,6 @@ class DedeTagParse | |||
| $this->CTags[$i]->IsReplace = TRUE; | |||
| $this->CTags[$i]->TagValue = $str; | |||
| } | |||
| //引入静态文件 | |||
| else if ($CTag->TagName == 'include') { | |||
| $filename = ($CTag->GetAtt('file') == '' ? $CTag->GetAtt('filename') : $CTag->GetAtt('file')); | |||
| @@ -566,7 +521,6 @@ class DedeTagParse | |||
| $this->CTags[$i]->IsReplace = TRUE; | |||
| $this->CTags[$i]->TagValue = $str; | |||
| } | |||
| //循环一个普通数组 | |||
| else if ($CTag->TagName == 'foreach') { | |||
| $arr = $this->CTags[$i]->GetAtt('array'); | |||
| @@ -580,7 +534,6 @@ class DedeTagParse | |||
| $this->CTags[$i]->IsReplace = TRUE; | |||
| $this->CTags[$i]->TagValue = $str; | |||
| } | |||
| //设置/获取变量值 | |||
| else if ($CTag->TagName == 'var') { | |||
| $vname = $this->CTags[$i]->GetAtt('name'); | |||
| @@ -594,7 +547,6 @@ class DedeTagParse | |||
| $this->CTags[$i]->IsReplace = TRUE; | |||
| $this->CTags[$i]->TagValue = $str; | |||
| } | |||
| //运行PHP接口 | |||
| if ($CTag->GetAtt('runphp') == 'yes') { | |||
| $this->RunPHP($CTag, $i); | |||
| @@ -604,7 +556,6 @@ class DedeTagParse | |||
| } | |||
| } | |||
| } | |||
| //运行PHP代码 | |||
| function RunPHP(&$refObj, $i) | |||
| { | |||
| @@ -626,7 +577,6 @@ class DedeTagParse | |||
| $this->CTags[$i]->TagValue = $DedeMeValue; | |||
| $this->CTags[$i]->IsReplace = TRUE; | |||
| } | |||
| /** | |||
| * 把分析模板输出到一个字符串中 | |||
| * 不替换没被处理的值 | |||
| @@ -659,7 +609,6 @@ class DedeTagParse | |||
| } | |||
| return $ResultString; | |||
| } | |||
| /** | |||
| * 把分析模板输出到一个字符串中,并返回 | |||
| * | |||
| @@ -686,7 +635,6 @@ class DedeTagParse | |||
| } | |||
| return $ResultString; | |||
| } | |||
| /** | |||
| * 直接输出解析模板 | |||
| * | |||
| @@ -697,7 +645,6 @@ class DedeTagParse | |||
| { | |||
| echo $this->GetResult(); | |||
| } | |||
| /** | |||
| * 把解析模板输出为文件 | |||
| * | |||
| @@ -707,11 +654,10 @@ class DedeTagParse | |||
| */ | |||
| function SaveTo($filename) | |||
| { | |||
| $fp = @fopen($filename, "w") or die("DedeTag Engine Create File False"); | |||
| $fp = @fopen($filename, "w") or die("请检查栏目文件保存目录是否填写正确"); | |||
| fwrite($fp, $this->GetResult()); | |||
| fclose($fp); | |||
| } | |||
| /** | |||
| * 解析模板 | |||
| * | |||
| @@ -729,17 +675,14 @@ class DedeTagParse | |||
| $eTagEndWord = "/".$TagEndWord; | |||
| $tsLen = strlen($FullTagStartWord); | |||
| $sourceLen = strlen($this->SourceString); | |||
| if ($sourceLen <= ($tsLen + 3)) { | |||
| return; | |||
| } | |||
| $cAtt = new DedeAttributeParse(); | |||
| $cAtt->charToLow = $this->CharToLow; | |||
| //遍历模板字符串,请取标记及其属性信息 | |||
| for ($i = 0; $i < $sourceLen; $i++) { | |||
| $tTagName = ''; | |||
| //如果不进行此判断,将无法识别相连的两个标记 | |||
| if ($i - 1 >= 0) { | |||
| $ss = $i - 1; | |||
| @@ -759,12 +702,6 @@ class DedeTagParse | |||
| break; | |||
| } | |||
| //判断是否已经到倒数第三个字符(可能性几率极小,取消此逻辑) | |||
| /* | |||
| if($sPos > ($sourceLen-$tsLen-3) ) | |||
| { | |||
| break; | |||
| } | |||
| */ | |||
| for ($j = ($sPos + $tsLen); $j < ($sPos + $tsLen + $this->TagMaxLen); $j++) { | |||
| if ($j > ($sourceLen - 1)) { | |||
| break; | |||
| @@ -778,13 +715,10 @@ class DedeTagParse | |||
| $i = $sPos + $tsLen; | |||
| $endPos = -1; | |||
| $fullTagEndWordThis = $sTagEndWord.$tTagName.$TagEndWord; | |||
| $e1 = strpos($this->SourceString, $eTagEndWord, $i); | |||
| $e2 = strpos($this->SourceString, $FullTagStartWord, $i); | |||
| $e3 = strpos($this->SourceString, $fullTagEndWordThis, $i); | |||
| //$eTagEndWord = /} $FullTagStartWord = {tag: $fullTagEndWordThis = {/tag:xxx] | |||
| $e1 = trim($e1); | |||
| $e2 = trim($e2); | |||
| $e3 = trim($e3); | |||
| @@ -812,7 +746,6 @@ class DedeTagParse | |||
| $elen = $endPos + strlen($fullTagEndWordThis); | |||
| } | |||
| } | |||
| //not found end tag , error | |||
| if ($endPos == -1) { | |||
| echo "Tag Character postion $sPos, '$tTagName' Error<br>\r\n"; | |||
| @@ -820,7 +753,6 @@ class DedeTagParse | |||
| } | |||
| $i = $elen; | |||
| $ePos = $endPos; | |||
| //分析所找到的标记位置等信息 | |||
| $attStr = ''; | |||
| $innerText = ''; | |||
| @@ -855,12 +787,10 @@ class DedeTagParse | |||
| break; | |||
| } | |||
| } //结束遍历模板字符串 | |||
| if ($this->IsCache) { | |||
| $this->SaveCache(); | |||
| } | |||
| } | |||
| /** | |||
| * 处理某字段的函数 | |||
| * | |||
| @@ -889,7 +819,6 @@ class DedeTagParse | |||
| return ''; | |||
| } | |||
| } | |||
| /** | |||
| * 获得一个外部变量 | |||
| * | |||
| @@ -900,12 +829,10 @@ class DedeTagParse | |||
| function GetGlobals($varname) | |||
| { | |||
| $varname = trim($varname); | |||
| //禁止在模板文件读取数据库密码 | |||
| if ($varname == "dbuserpwd" || $varname == "cfg_dbpwd") { | |||
| return ""; | |||
| } | |||
| //正常情况 | |||
| if (isset($GLOBALS[$varname])) { | |||
| return $GLOBALS[$varname]; | |||
| @@ -913,7 +840,6 @@ class DedeTagParse | |||
| return ""; | |||
| } | |||
| } | |||
| /** | |||
| * 引入文件 | |||
| * | |||
| @@ -929,14 +855,13 @@ class DedeTagParse | |||
| if ($filename == '') { | |||
| return ''; | |||
| } | |||
| if (file_exists(DEDEROOT."/templets/".$filename)) { | |||
| $okfile = DEDEROOT."/templets/".$filename; | |||
| } else if (file_exists(DEDEROOT.'/templets/'.$cfg_df_style.'/'.$filename)) { | |||
| $okfile = DEDEROOT.'/templets/'.$cfg_df_style.'/'.$filename; | |||
| if (file_exists(DEDEROOT."/theme/".$filename)) { | |||
| $okfile = DEDEROOT."/theme/".$filename; | |||
| } else if (file_exists(DEDEROOT.'/theme/'.$cfg_df_style.'/'.$filename)) { | |||
| $okfile = DEDEROOT.'/theme/'.$cfg_df_style.'/'.$filename; | |||
| } else { | |||
| return "无法在这个位置找到:$filename"; | |||
| } | |||
| //编译 | |||
| if ($ismake != "no") { | |||
| require_once(DEDEINC."/channelunit.func.php"); | |||
| @@ -952,7 +877,6 @@ class DedeTagParse | |||
| return $restr; | |||
| } | |||
| } | |||
| /********************************************** | |||
| //class DedeAttribute Dede模板标记属性集合 | |||
| function c____DedeAttribute(); | |||
| @@ -974,33 +898,28 @@ class DedeAttribute | |||
| return ""; | |||
| } | |||
| } | |||
| //同上 | |||
| function GetAttribute($str) | |||
| { | |||
| return $this->GetAtt($str); | |||
| } | |||
| //判断属性是否存在 | |||
| function IsAttribute($str) | |||
| { | |||
| if (isset($this->Items[$str])) return TRUE; | |||
| else return FALSE; | |||
| } | |||
| //获得标记名称 | |||
| function GetTagName() | |||
| { | |||
| return $this->GetAtt("tagname"); | |||
| } | |||
| //获得属性个数 | |||
| function GetCount() | |||
| { | |||
| return $this->Count + 1; | |||
| } | |||
| } | |||
| /******************************* | |||
| //属性解析器(本版本中已经支持使用\'这种语法,和用.间隔表示name属性,如 field.body) | |||
| function c____DedeAttributeParse(); | |||
| @@ -1016,23 +935,14 @@ class DedeAttributeParse | |||
| $this->cAttributes = new DedeAttribute(); | |||
| $strLen = 0; | |||
| $this->sourceString = trim(preg_replace("/[ \r\n\t]{1,}/", " ", $str)); | |||
| //为了在function内能使用数组,这里允许对[ ]进行转义使用 | |||
| $this->sourceString = str_replace('\]', ']', $this->sourceString); | |||
| $this->sourceString = str_replace('[', '[', $this->sourceString); | |||
| /* | |||
| $this->sourceString = str_replace('\>','>',$this->sourceString); | |||
| $this->sourceString = str_replace('<','>',$this->sourceString); | |||
| $this->sourceString = str_replace('{','{',$this->sourceString); | |||
| $this->sourceString = str_replace('\}','}',$this->sourceString); | |||
| */ | |||
| $strLen = strlen($this->sourceString); | |||
| if ($strLen > 0 && $strLen <= $this->sourceMaxSize) { | |||
| $this->ParseAttribute(); | |||
| } | |||
| } | |||
| //解析属性 | |||
| function ParseAttribute() | |||
| { | |||
| @@ -1044,7 +954,6 @@ class DedeAttributeParse | |||
| $hasAttribute = FALSE; | |||
| $strLen = strlen($this->sourceString); | |||
| $this->cAttributes->Items = array(); | |||
| //获得Tag的名称,解析到 cAtt->GetAtt('tagname') 中 | |||
| for ($i = 0; $i < $strLen; $i++) { | |||
| if ($this->sourceString[$i] == ' ') { | |||
| @@ -1061,7 +970,6 @@ class DedeAttributeParse | |||
| $tmpvalue .= $this->sourceString[$i]; | |||
| } | |||
| } | |||
| //不存在属性列表的情况 | |||
| if (!$hasAttribute) { | |||
| $this->cAttributes->Count++; | |||
| @@ -1073,7 +981,6 @@ class DedeAttributeParse | |||
| return; | |||
| } | |||
| $tmpvalue = ''; | |||
| //如果字符串含有属性值,遍历源字符串,并获得各属性 | |||
| for ($i; $i < $strLen; $i++) { | |||
| $d = $this->sourceString[$i]; | |||
| @@ -1090,7 +997,6 @@ class DedeAttributeParse | |||
| $startdd = 0; | |||
| } | |||
| } | |||
| //查找属性的限定标志 | |||
| else if ($startdd == 0) { | |||
| switch ($d) { | |||
| @@ -1121,8 +1027,7 @@ class DedeAttributeParse | |||
| $tmpvalue .= $d; | |||
| } | |||
| } | |||
| } //for | |||
| }//for | |||
| //最后一个属性的给值 | |||
| if ($tmpatt != '') { | |||
| $this->cAttributes->Count++; | |||
| @@ -1130,4 +1035,4 @@ class DedeAttributeParse | |||
| } | |||
| //print_r($this->cAttributes->Items); | |||
| } //end func | |||
| } | |||
| } | |||
| @@ -43,7 +43,6 @@ function MakePublicTag($atts = array(), $refObj = '', $fields = array()) | |||
| return $func($atts, $refObj, $fields); | |||
| } | |||
| } | |||
| /** | |||
| * 设定属性的默认值 | |||
| * | |||
| @@ -62,7 +61,6 @@ function FillAtts(&$atts, $attlist) | |||
| } | |||
| } | |||
| } | |||
| /** | |||
| * 把上级的fields传递给atts | |||
| * | |||
| @@ -94,7 +92,6 @@ function FillFields(&$atts, &$refObj, &$fields) | |||
| } | |||
| } | |||
| } | |||
| /** | |||
| * class Tag 标记的数据结构描述 | |||
| * function C__Tag(); | |||
| @@ -113,7 +110,6 @@ class Tag | |||
| var $cAtt; //标记属性描述,即是class TagAttribute | |||
| var $tagValue = ""; //标记的值 | |||
| var $tagID = 0; | |||
| /** | |||
| * 获取标记的名称和值 | |||
| * | |||
| @@ -124,22 +120,18 @@ class Tag | |||
| { | |||
| return strtolower($this->tagName); | |||
| } | |||
| function GetValue() | |||
| { | |||
| return $this->tagValue; | |||
| } | |||
| function IsAtt($str) | |||
| { | |||
| return $this->cAtt->IsAttribute($str); | |||
| } | |||
| function GetAtt($str) | |||
| { | |||
| return $this->cAtt->GetAtt($str); | |||
| } | |||
| /** | |||
| * 获取底层模板 | |||
| * | |||
| @@ -150,7 +142,6 @@ class Tag | |||
| return $this->innerText; | |||
| } | |||
| } | |||
| /** | |||
| * 模板解析器 | |||
| * function C__DedeTemplate | |||
| @@ -176,8 +167,6 @@ class DedeTemplate | |||
| var $templateFile = ''; | |||
| var $sourceString = ''; | |||
| var $cTags = array(); | |||
| //var $definedVars = array(); | |||
| var $count = -1; | |||
| var $loopNum = 0; | |||
| var $refObj = ''; | |||
| @@ -187,8 +176,6 @@ class DedeTemplate | |||
| var $sTagEndWord = '/}'; | |||
| var $tagEndWord = '}'; | |||
| var $tpCfgs = array(); | |||
| /** | |||
| * 析构函数 | |||
| * | |||
| @@ -199,14 +186,12 @@ class DedeTemplate | |||
| */ | |||
| function __construct($templatedir = '', $refDir = '') | |||
| { | |||
| //$definedVars[] = 'var'; | |||
| //缓存目录 | |||
| if ($templatedir == '') { | |||
| $this->templateDir = DEDEROOT.'/templates'; | |||
| } else { | |||
| $this->templateDir = $templatedir; | |||
| } | |||
| //模板include目录 | |||
| if ($refDir == '') { | |||
| if (isset($GLOBALS['cfg_df_style'])) { | |||
| @@ -217,13 +202,11 @@ class DedeTemplate | |||
| } | |||
| $this->cacheDir = DEDEROOT.$GLOBALS['cfg_tplcache_dir']; | |||
| } | |||
| //构造函数,兼容PHP4 | |||
| //构造函数,兼容PHP4 | |||
| function DedeTemplate($templatedir = '', $refDir = '') | |||
| { | |||
| $this->__construct($templatedir, $refDir); | |||
| } | |||
| /** | |||
| * 设定本类自身实例的类引用和使用本类的类实例(如果在类中使用本模板引擎,后一参数一般为$this) | |||
| * | |||
| @@ -235,7 +218,6 @@ class DedeTemplate | |||
| { | |||
| $this->refObj = $refObj; | |||
| } | |||
| /** | |||
| * 设定Var的键值对 | |||
| * | |||
| @@ -248,7 +230,6 @@ class DedeTemplate | |||
| { | |||
| $GLOBALS['_vars'][$k] = $v; | |||
| } | |||
| /** | |||
| * 设定Var的键值对 | |||
| * | |||
| @@ -261,7 +242,6 @@ class DedeTemplate | |||
| { | |||
| $GLOBALS['_vars'][$k] = $v; | |||
| } | |||
| /** | |||
| * 设定数组 | |||
| * | |||
| @@ -274,7 +254,6 @@ class DedeTemplate | |||
| { | |||
| $GLOBALS[$k] = $v; | |||
| } | |||
| /** | |||
| * 设置标记风格 | |||
| * | |||
| @@ -292,7 +271,6 @@ class DedeTemplate | |||
| $this->sTagEndWord = $stend; | |||
| $this->tagEndWord = $tend; | |||
| } | |||
| /** | |||
| * 获得模板设定的config值 | |||
| * | |||
| @@ -304,7 +282,6 @@ class DedeTemplate | |||
| { | |||
| return (isset($this->tpCfgs[$k]) ? $this->tpCfgs[$k] : ''); | |||
| } | |||
| /** | |||
| * 设定模板文件 | |||
| * | |||
| @@ -337,7 +314,6 @@ class DedeTemplate | |||
| } | |||
| $this->cacheFile = $this->cacheDir.preg_replace("/\.(wml|html|htm|php)$/", "_".$this->GetEncodeStr($tmpfile).'.inc', $tmpfileOnlyName); | |||
| $this->configFile = $this->cacheDir.preg_replace("/\.(wml|html|htm|php)$/", "_".$this->GetEncodeStr($tmpfile).'_config.inc', $tmpfileOnlyName); | |||
| //不开启缓存、当缓存文件不存在、及模板为更新的文件的时候才载入模板并进行解析 | |||
| if ( | |||
| $this->isCache == FALSE || !file_exists($this->cacheFile) | |||
| @@ -358,7 +334,6 @@ class DedeTemplate | |||
| } | |||
| } | |||
| } | |||
| /** | |||
| * 载入模板字符串 | |||
| * | |||
| @@ -374,7 +349,6 @@ class DedeTemplate | |||
| $this->configFile = $this->cacheDir."/string_".$hashcode."_config.inc"; | |||
| $this->ParseTemplate(); | |||
| } | |||
| /** | |||
| * 调用此函数include一个编译后的PHP文件,通常是在最后一个步骤才调用本文件 | |||
| * | |||
| @@ -387,7 +361,6 @@ class DedeTemplate | |||
| $this->WriteCache(); | |||
| return $this->cacheFile; | |||
| } | |||
| /** | |||
| * 显示内容,由于函数中会重新解压一次$GLOBALS变量,所以在动态页中,应该尽量少用本方法, | |||
| * 取代之是直接在程序中 include $tpl->CacheFile(),不过include $tpl->CacheFile()这种方式不能在类或函数内使用 | |||
| @@ -403,7 +376,6 @@ class DedeTemplate | |||
| $this->WriteCache(); | |||
| include $this->cacheFile; | |||
| } | |||
| /** | |||
| * 保存运行后的程序为文件 | |||
| * | |||
| @@ -423,9 +395,6 @@ class DedeTemplate | |||
| fwrite($fp, $okstr); | |||
| fclose($fp); | |||
| } | |||
| //------------------------------------------------------------------------ | |||
| /** | |||
| * CheckDisabledFunctions | |||
| * | |||
| @@ -454,7 +423,6 @@ class DedeTemplate | |||
| } | |||
| return TRUE; | |||
| } | |||
| /** | |||
| * 解析模板并写缓存文件 | |||
| * | |||
| @@ -475,7 +443,6 @@ class DedeTemplate | |||
| flock($fp, 3); | |||
| $result = trim($this->GetResult()); | |||
| $errmsg = ''; | |||
| //var_dump($result);exit(); | |||
| if (!$this->CheckDisabledFunctions($result, $errmsg)) { | |||
| fclose($fp); | |||
| @unlink($this->cacheFile); | |||
| @@ -496,58 +463,7 @@ class DedeTemplate | |||
| fclose($fp); | |||
| } | |||
| } | |||
| /* | |||
| if(!file_exists($this->cacheFile) || $this->isCache==FALSE | |||
| || ( file_exists($this->templateFile) && (filemtime($this->templateFile) > filemtime($this->cacheFile)) ) ) | |||
| { | |||
| if($ctype!='config') | |||
| { | |||
| if(!$this->isParse) | |||
| { | |||
| $this->ParseTemplate(); | |||
| } | |||
| $fp = fopen($this->cacheFile,'w') or dir("Write Cache File Error! "); | |||
| flock($fp,3); | |||
| fwrite($fp,trim($this->GetResult())); | |||
| fclose($fp); | |||
| } | |||
| else | |||
| { | |||
| if(count($this->tpCfgs) > 0) | |||
| { | |||
| $fp = fopen($this->configFile,'w') or dir("Write Config File Error! "); | |||
| flock($fp,3); | |||
| fwrite($fp,'<'.'?php'."\r\n"); | |||
| foreach($this->tpCfgs as $k=>$v) | |||
| { | |||
| $v = str_replace("\"","\\\"",$v); | |||
| $v = str_replace("\$","\\\$",$v); | |||
| fwrite($fp,"\$this->tpCfgs['$k']=\"$v\";\r\n"); | |||
| } | |||
| fwrite($fp,'?'.'>'); | |||
| fclose($fp); | |||
| } | |||
| } | |||
| } else { | |||
| if($ctype=='config' && count($this->tpCfgs) > 0 ) | |||
| { | |||
| $fp = fopen($this->configFile,'w') or dir("Write Config File Error! "); | |||
| flock($fp,3); | |||
| fwrite($fp,'<'.'?php'."\r\n"); | |||
| foreach($this->tpCfgs as $k=>$v) | |||
| { | |||
| $v = str_replace("\"","\\\"",$v); | |||
| $v = str_replace("\$","\\\$",$v); | |||
| fwrite($fp,"\$this->tpCfgs['$k']=\"$v\";\r\n"); | |||
| } | |||
| fwrite($fp,'?'.'>'); | |||
| fclose($fp); | |||
| } | |||
| } | |||
| */ | |||
| } | |||
| /** | |||
| * 获得模板文件名的md5字符串 | |||
| * | |||
| @@ -561,7 +477,6 @@ class DedeTemplate | |||
| $encodeStr = substr(md5($tmpfile), 0, 24); | |||
| return $encodeStr; | |||
| } | |||
| /** | |||
| * 解析模板 | |||
| * | |||
| @@ -589,14 +504,12 @@ class DedeTemplate | |||
| } | |||
| $cAtt = new TagAttributeParse(); | |||
| $cAtt->CharToLow = TRUE; | |||
| //遍历模板字符串,请取标记及其属性信息 | |||
| $t = 0; | |||
| $preTag = ''; | |||
| $tswLen = strlen($tagStartWord); | |||
| for ($i = 0; $i < $sourceLen; $i++) { | |||
| $ttagName = ''; | |||
| //如果不进行此判断,将无法识别相连的两个标记 | |||
| if ($i - 1 >= 0) { | |||
| $ss = $i - 1; | |||
| @@ -604,14 +517,12 @@ class DedeTemplate | |||
| $ss = 0; | |||
| } | |||
| $tagPos = strpos($this->sourceString, $tagStartWord, $ss); | |||
| //判断后面是否还有模板标记 | |||
| if ($tagPos == 0 && ($sourceLen - $i < $tswLen | |||
| || substr($this->sourceString, $i, $tswLen) != $tagStartWord)) { | |||
| $tagPos = -1; | |||
| break; | |||
| } | |||
| //获取TAG基本信息 | |||
| for ($j = $tagPos + $startWordLen; $j < $tagPos + $startWordLen + $this->tagMaxLen; $j++) { | |||
| if (preg_match("/[ >\/\r\n\t\}\.]/", $this->sourceString[$j])) { | |||
| @@ -623,7 +534,6 @@ class DedeTemplate | |||
| if ($ttagName != '') { | |||
| $i = $tagPos + $startWordLen; | |||
| $endPos = -1; | |||
| //判断 '/}' '{tag:下一标记开始' '{/tag:标记结束' 谁最靠近 | |||
| $fullTagEndWordThis = $fullTagEndWord.$ttagName.$tagEndWord; | |||
| $e1 = strpos($this->sourceString, $sTagEndWord, $i); | |||
| @@ -644,7 +554,6 @@ class DedeTemplate | |||
| $endPos = $e3; | |||
| $elen = $endPos + strlen($fullTagEndWordThis); | |||
| } | |||
| //同时存在 '/}' 和 '{/tag:标记' | |||
| else { | |||
| //如果 '/}' 比 '{tag:'、'{/tag:标记' 都要靠近,则认为结束标志是 '/}',否则结束标志为 '{/tag:标记' | |||
| @@ -656,14 +565,12 @@ class DedeTemplate | |||
| $elen = $endPos + strlen($fullTagEndWordThis); | |||
| } | |||
| } | |||
| //如果找不到结束标记,则认为这个标记存在错误 | |||
| if ($endPos == -1) { | |||
| echo "Tpl Character postion $tagPos, '$ttagName' Error<br>\r\n"; | |||
| break; | |||
| } | |||
| $i = $elen; | |||
| //分析所找到的标记位置等信息 | |||
| $attStr = ''; | |||
| $innerText = ''; | |||
| @@ -681,7 +588,6 @@ class DedeTemplate | |||
| } | |||
| } | |||
| $ttagName = strtolower($ttagName); | |||
| //if、php标记,把整个属性串视为属性 | |||
| if (preg_match("/^if[0-9]{0,}$/", $ttagName)) { | |||
| $cAtt->cAttributes = new TagAttribute(); | |||
| @@ -716,13 +622,11 @@ class DedeTemplate | |||
| $i = $tagPos + $startWordLen; | |||
| break; | |||
| } | |||
| } //结束遍历模板字符串 | |||
| }//结束遍历模板字符串 | |||
| if ($this->count > -1 && $this->isCompiler) { | |||
| $this->CompilerAll(); | |||
| } | |||
| } | |||
| /** | |||
| * 把模板标记转换为PHP代码 | |||
| * | |||
| @@ -733,7 +637,7 @@ class DedeTemplate | |||
| { | |||
| $this->loopNum++; | |||
| if ($this->loopNum > 10) { | |||
| return; //限制最大递归深度为 10 以防止因标记出错等可能性导致死循环 | |||
| return;//限制最大递归深度为 10 以防止因标记出错等可能性导致死循环 | |||
| } | |||
| $ResultString = ''; | |||
| $nextTagEnd = 0; | |||
| @@ -749,8 +653,6 @@ class DedeTemplate | |||
| $this->sourceString = $ResultString; | |||
| $this->ParseTemplate(); | |||
| } | |||
| /** | |||
| * 获得最终结果 | |||
| * | |||
| @@ -766,7 +668,6 @@ class DedeTemplate | |||
| $addset .= '<'.'?php'."\r\n".'if(!isset($GLOBALS[\'_vars\'])) $GLOBALS[\'_vars\'] = array(); '."\r\n".'$fields = array();'."\r\n".'?'.'>'; | |||
| return preg_replace("/\?".">[ \r\n\t]{0,}<"."\?php/", "", $addset.$this->sourceString); | |||
| } | |||
| /** | |||
| * 编译单个标记 | |||
| * | |||
| @@ -780,7 +681,6 @@ class DedeTemplate | |||
| $tagname = $cTag->tagName; | |||
| $varname = $cTag->GetAtt('name'); | |||
| $rsvalue = ""; | |||
| //用于在模板中设置一个变量以提供作扩展用途 | |||
| //此变量直接提交到 this->tpCfgs 中,并会生成与模板对应的缓存文件 ***_config.php 文件 | |||
| if ($tagname == 'config') { | |||
| @@ -847,7 +747,6 @@ class DedeTemplate | |||
| $cTag->tagValue = '<'."?php\r\n".trim($cTag->GetInnerText())."\r\n?".'>'; | |||
| } | |||
| } | |||
| //遍历数组 | |||
| else if (preg_match("/^array[0-9]{0,}/", $tagname)) { | |||
| $kk = '$key'; | |||
| @@ -870,8 +769,7 @@ class DedeTemplate | |||
| $rsvalue .= '<'.'?php } ?'.">\r\n"; | |||
| $cTag->tagValue = $rsvalue; | |||
| } | |||
| //include 文件 | |||
| //system文件 | |||
| else if ($tagname == 'include') { | |||
| $filename = $cTag->GetAtt('file'); | |||
| if ($filename == '') { | |||
| @@ -912,7 +810,6 @@ class DedeTemplate | |||
| $bindType = $cTag->GetAtt('bindtype'); | |||
| $rstype = ($cTag->GetAtt('resulttype') == '' ? $cTag->GetAtt('rstype') : $cTag->GetAtt('resulttype')); | |||
| $rstype = strtolower($rstype); | |||
| //生成属性数组 | |||
| foreach ($cTag->cAtt->items as $k => $v) { | |||
| if (preg_match("/(bind|bindtype)/i", $k)) { | |||
| @@ -922,7 +819,6 @@ class DedeTemplate | |||
| $rsvalue .= '$atts[\''.$k.'\'] = \''.str_replace("'", "\\'", $v)."';\r\n"; | |||
| } | |||
| $rsvalue = '<'.'?php'."\r\n".'$atts = array();'."\r\n".$rsvalue; | |||
| //绑定到默认函数还是指定函数(datasource属性指定) | |||
| if ($bindFunc == '') { | |||
| $rsvalue .= '$blockValue = MakePublicTag($atts,$this->refObj,$fields); '."\r\n"; | |||
| @@ -931,7 +827,6 @@ class DedeTemplate | |||
| if ($bindType == '') $rsvalue .= '$blockValue = $this->refObj->'.$bindFunc.'($atts,$this->refObj,$fields); '."\r\n"; | |||
| else $rsvalue .= '$blockValue = '.$bindFunc.'($atts,$this->refObj,$fields); '."\r\n"; | |||
| } | |||
| //返回结果类型:默认为 array 是一个二维数组,string 是字符串 | |||
| if ($rstype == 'string') { | |||
| $rsvalue .= 'echo $blockValue;'."\r\n".'?'.">"; | |||
| @@ -945,7 +840,6 @@ class DedeTemplate | |||
| } | |||
| return $cTag->tagValue; | |||
| } | |||
| /** | |||
| * 编译可能为数组的变量 | |||
| * | |||
| @@ -957,7 +851,6 @@ class DedeTemplate | |||
| function CompilerArrayVar($vartype, $varname) | |||
| { | |||
| $okvalue = ''; | |||
| if (!preg_match("/\[/", $varname)) { | |||
| if (preg_match("/^value/", $vartype)) { | |||
| $varname = $vartype.'.'.$varname; | |||
| @@ -970,7 +863,6 @@ class DedeTemplate | |||
| } | |||
| } | |||
| } | |||
| if (preg_match("/\[/", $varname)) { | |||
| $varnames = explode('[', $varname); | |||
| $arrend = ''; | |||
| @@ -1004,7 +896,6 @@ class DedeTemplate | |||
| } | |||
| return $okvalue; | |||
| } | |||
| /** | |||
| * 编译if标记 | |||
| * | |||
| @@ -1029,7 +920,6 @@ class DedeTemplate | |||
| $rsvalue .= '<'.'?php } ?'.'>'; | |||
| return $rsvalue; | |||
| } | |||
| /** | |||
| * 处理block区块传递的atts属性的值 | |||
| * | |||
| @@ -1043,7 +933,6 @@ class DedeTemplate | |||
| $v = str_replace('?'.'>', '?>', $v); | |||
| return $v; | |||
| } | |||
| /** | |||
| * 函数 function 语法处理 | |||
| * | |||
| @@ -1058,9 +947,8 @@ class DedeTemplate | |||
| $funcstr = str_replace('@me', $nvalue, $funcstr); | |||
| return $funcstr; | |||
| } | |||
| /** | |||
| * 引入文件 include 语法处理 | |||
| * 引入文件system语法处理 | |||
| * | |||
| * @access public | |||
| * @param string $filename 文件名 | |||
| @@ -1086,7 +974,6 @@ class DedeTemplate | |||
| return $itpl->CacheFile(); | |||
| } | |||
| } | |||
| /** | |||
| * class TagAttribute Tag属性集合 | |||
| * function C__TagAttribute(); | |||
| @@ -1100,7 +987,6 @@ class TagAttribute | |||
| { | |||
| var $count = -1; | |||
| var $items = array(); //属性元素的集合 | |||
| /** | |||
| * 获得某个属性 | |||
| * | |||
| @@ -1119,7 +1005,6 @@ class TagAttribute | |||
| return ""; | |||
| } | |||
| } | |||
| /** | |||
| * 同上 | |||
| * | |||
| @@ -1131,7 +1016,6 @@ class TagAttribute | |||
| { | |||
| return $this->GetAtt($str); | |||
| } | |||
| /** | |||
| * 判断属性是否存在 | |||
| * | |||
| @@ -1144,7 +1028,6 @@ class TagAttribute | |||
| if (isset($this->items[$str])) return TRUE; | |||
| else return FALSE; | |||
| } | |||
| /** | |||
| * 获得标记名称 | |||
| * | |||
| @@ -1155,7 +1038,6 @@ class TagAttribute | |||
| { | |||
| return $this->GetAtt("tagname"); | |||
| } | |||
| /** | |||
| * 获得属性个数 | |||
| * | |||
| @@ -1166,8 +1048,7 @@ class TagAttribute | |||
| { | |||
| return $this->count + 1; | |||
| } | |||
| } //End Class | |||
| }//End Class | |||
| /** | |||
| * 属性解析器 | |||
| * function C__TagAttributeParse(); | |||
| @@ -1192,7 +1073,6 @@ class TagAttributeParse | |||
| $this->ParseAttribute(); | |||
| } | |||
| } | |||
| /** | |||
| * 解析属性 | |||
| * | |||
| @@ -1209,7 +1089,6 @@ class TagAttributeParse | |||
| $hasAttribute = FALSE; | |||
| $strLen = strlen($this->sourceString); | |||
| $this->cAttributes->items = array(); | |||
| //获得Tag的名称,解析到 cAtt->GetAtt('tagname') 中 | |||
| for ($i = 0; $i < $strLen; $i++) { | |||
| if ($this->sourceString[$i] == ' ') { | |||
| @@ -1232,7 +1111,6 @@ class TagAttributeParse | |||
| $tmpvalue .= $this->sourceString[$i]; | |||
| } | |||
| } | |||
| //不存在属性列表的情况 | |||
| if (!$hasAttribute) { | |||
| $this->cAttributes->count++; | |||
| @@ -1250,7 +1128,6 @@ class TagAttributeParse | |||
| return; | |||
| } | |||
| $tmpvalue = ''; | |||
| //如果字符串含有属性值,遍历源字符串,并获得各属性 | |||
| for ($i; $i < $strLen; $i++) { | |||
| $d = $this->sourceString[$i]; | |||
| @@ -1267,7 +1144,6 @@ class TagAttributeParse | |||
| $startdd = 0; | |||
| } | |||
| } | |||
| //查找属性的限定标志 | |||
| else if ($startdd == 0) { | |||
| switch ($d) { | |||
| @@ -1299,17 +1175,13 @@ class TagAttributeParse | |||
| } | |||
| } | |||
| } //for | |||
| //最后一个属性的给值 | |||
| if ($tmpatt != '') { | |||
| $this->cAttributes->count++; | |||
| $this->cAttributes->items[$tmpatt] = trim($tmpvalue); | |||
| } //print_r($this->cAttributes->items); | |||
| } //end func | |||
| } //End Class | |||
| /** | |||
| * 私有标签编译,主要用于if标签内的字符串解析 | |||
| * | |||
| @@ -1324,7 +1196,6 @@ function private_rt($str) | |||
| } else { | |||
| $arr = explode('.', $str); | |||
| } | |||
| $rs = '$GLOBALS[\''; | |||
| if ($arr[0] == 'cfg') { | |||
| return $rs.'cfg_'.$arr[1]."']"; | |||
| @@ -1346,4 +1217,4 @@ function private_rt($str) | |||
| $rs .= "']"; | |||
| return $rs; | |||
| } | |||
| } | |||
| } | |||
| @@ -10,7 +10,6 @@ if (!defined('DEDEINC')) exit('dedebiz'); | |||
| * @link https://www.dedebiz.com | |||
| */ | |||
| require_once(DEDEINC."/dedetag.class.php"); | |||
| /** | |||
| * 投票类 | |||
| * | |||
| @@ -25,7 +24,6 @@ class DedeVote | |||
| var $VoteCount; | |||
| var $VoteID; | |||
| var $dsql; | |||
| //php5构造函数 | |||
| function __construct($aid) | |||
| { | |||
| @@ -54,11 +52,9 @@ class DedeVote | |||
| { | |||
| $this->__construct($aid); | |||
| } | |||
| function Close() | |||
| { | |||
| } | |||
| /** | |||
| * 获得投票项目总投票次数 | |||
| * | |||
| @@ -73,7 +69,6 @@ class DedeVote | |||
| return 0; | |||
| } | |||
| } | |||
| /** | |||
| * 增加指定的投票节点的票数 | |||
| * | |||
| @@ -87,7 +82,6 @@ class DedeVote | |||
| $this->VoteNotes[$aid]['count']++; | |||
| } | |||
| } | |||
| /** | |||
| * 获得项目的投票表单 | |||
| * | |||
| @@ -128,7 +122,6 @@ class DedeVote | |||
| $items .= "<input type='hidden' name='ismore' value='".$this->VoteInfos['ismore']."' />\r\n"; | |||
| $items .= "<tr align='center'><td height='$lineheight' id='votetitle' style='border-bottom:1px dashed #999999;color:#3F7652' $titlebackgroup><strong>".$this->VoteInfos['votename']."</strong></td></tr>\r\n"; | |||
| if ($this->VoteCount > 0) { | |||
| foreach ($this->VoteNotes as $k => $arr) { | |||
| if ($this->VoteInfos['ismore'] == 0) { | |||
| $items .= "<tr><td height=$lineheight bgcolor=$itembgcolor style='color:#666666'><label><input type='radio' name='voteitem' value='$k' /> ".$arr['name']."</label></td></tr>\r\n"; | |||
| @@ -144,7 +137,6 @@ class DedeVote | |||
| $items .= "</form>\r\n</table>\r\n"; | |||
| return $items; | |||
| } | |||
| /** | |||
| * 保存投票数据 | |||
| * 请不要在输出任何内容之前使用SaveVote()方法! | |||
| @@ -160,7 +152,6 @@ class DedeVote | |||
| return '您没选中任何项目'; | |||
| } | |||
| $items = ''; | |||
| //检查投票是否已过期 | |||
| $nowtime = time(); | |||
| if ($nowtime > $this->VoteInfos['endtime']) { | |||
| @@ -172,7 +163,6 @@ class DedeVote | |||
| ShowMsg('投票还没有开始', $ENV_GOBACK_URL); | |||
| exit(); | |||
| } | |||
| //检测游客是否已投过票 | |||
| if (isset($_COOKIE['VOTE_MEMBER_IP'])) { | |||
| if ($_COOKIE['VOTE_MEMBER_IP'] == $_SERVER['REMOTE_ADDR']) { | |||
| @@ -184,7 +174,6 @@ class DedeVote | |||
| } else { | |||
| setcookie('VOTE_MEMBER_IP', $_SERVER['REMOTE_ADDR'], time() * $row['spec'] * 3600, '/'); | |||
| } | |||
| //检查用户是否已投过票 | |||
| $nowtime = time(); | |||
| $VoteMem = $this->dsql->GetOne("SELECT * FROM #@__vote_member WHERE voteid = '$this->VoteID' and userid='$memberID'"); | |||
| @@ -234,7 +223,6 @@ class DedeVote | |||
| $this->dsql->ExecuteNoneQuery("UPDATE `#@__vote` SET totalcount='".($this->VoteInfos['totalcount'] + 1)."',votenote='".addslashes($items)."' WHERE aid='".$this->VoteID."'"); | |||
| return "投票成功"; | |||
| } | |||
| /** | |||
| * 获得项目的投票结果 | |||
| * | |||
| @@ -11,7 +11,6 @@ if (!defined('DEDEINC')) exit('dedebiz'); | |||
| */ | |||
| require_once DEDEINC.'/dedetag.class.php'; | |||
| require_once DEDEINC.'/customfields.func.php'; | |||
| /** | |||
| * diyform | |||
| * | |||
| @@ -30,7 +29,6 @@ class diyform | |||
| var $listTemplate; | |||
| var $viewTemplate; | |||
| var $postTemplate; | |||
| function diyform($diyid) | |||
| { | |||
| $this->__construct($diyid); | |||
| @@ -60,7 +58,6 @@ class diyform | |||
| $this->viewTemplate = $diyinfo['viewtemplate'] != '' && file_exists(DEDETEMPLATE.'/plus/'.$diyinfo['viewtemplate']) ? $diyinfo['viewtemplate'] : 'view_diyform.htm';; | |||
| $this->postTemplate = $diyinfo['posttemplate'] != '' && file_exists(DEDETEMPLATE.'/plus/'.$diyinfo['posttemplate']) ? $diyinfo['posttemplate'] : 'post_diyform.htm';; | |||
| } | |||
| /** | |||
| * 获取表单 | |||
| * | |||
| @@ -91,12 +88,10 @@ class diyform | |||
| } | |||
| } | |||
| } | |||
| $formstring .= "<input type=\"hidden\" name=\"dede_fields\" value=\"".$formfields."\" />\n"; | |||
| $formstring .= "<input type=\"hidden\" name=\"dede_fieldshash\" value=\"".md5($formfields.$cfg_cookie_encode)."\" />"; | |||
| return $formstring; | |||
| } | |||
| /** | |||
| * 获取字段列表 | |||
| * | |||
| @@ -11,4 +11,4 @@ if (!defined('DEDEINC')) exit('dedebiz'); | |||
| */ | |||
| //引入小助手 | |||
| //本版本的文件暂时仅作一个映射,今后开发直接采用helper('downmix');进行调用 | |||
| helper('downmix'); | |||
| helper('downmix'); | |||
| @@ -52,7 +52,6 @@ function WriteEnumsCache($egroup = '') | |||
| } | |||
| return '成功更新所有枚举缓存'; | |||
| } | |||
| /** | |||
| * 获取联动表单两级数据的父类与子类 | |||
| * | |||
| @@ -72,7 +71,6 @@ function GetEnumsTypes($v) | |||
| } | |||
| return $rearr; | |||
| } | |||
| /** | |||
| * 获取枚举的select表单 | |||
| * | |||
| @@ -105,7 +103,6 @@ function GetEnumsForm($egroup, $evalue = 0, $formid = '', $seltitle = '') | |||
| $forms .= "</select>"; | |||
| return $forms; | |||
| } | |||
| /** | |||
| * 获取一级数据 | |||
| * | |||
| @@ -125,8 +122,6 @@ function getTopData($egroup) | |||
| } | |||
| return $data; | |||
| } | |||
| /** | |||
| * 获取数据的JS代码(二级联动) | |||
| * | |||
| @@ -152,7 +147,6 @@ function GetEnumsJs($egroup) | |||
| $jsCode .= "-->"; | |||
| return $jsCode; | |||
| } | |||
| /** | |||
| * 写入联动JS代码 | |||
| * | |||
| @@ -167,8 +161,6 @@ function WriteEnumsJs($egroup) | |||
| fwrite($fp, GetEnumsJs($egroup)); | |||
| fclose($fp); | |||
| } | |||
| /** | |||
| * 获取枚举的值 | |||
| * | |||
| @@ -185,4 +177,4 @@ function GetEnumsValue($egroup, $evalue = 0) | |||
| } else { | |||
| return "保密"; | |||
| } | |||
| } | |||
| } | |||
| @@ -46,10 +46,9 @@ function _FilterAll($fk, &$svar) | |||
| } | |||
| return $svar; | |||
| } | |||
| /* 对_GET,_POST,_COOKIE进行过滤 */ | |||
| foreach (array('_GET', '_POST', '_COOKIE') as $_request) { | |||
| foreach ($$_request as $_k => $_v) { | |||
| ${$_k} = _FilterAll($_k, $_v); | |||
| } | |||
| } | |||
| } | |||
| @@ -21,13 +21,11 @@ class image | |||
| var $watermarktext; | |||
| var $thumbstatus; | |||
| var $watermarkstatus; | |||
| //析构函数,兼容PHP4 | |||
| function image($targetfile, $cfg_thumb, $cfg_watermarktext, $photo_waterpos, $photo_diaphaneity, $photo_wheight, $photo_wwidth, $cfg_watermarktype, $photo_marktrans, $trueMarkimg, $attach = array()) | |||
| { | |||
| $this->__construct($targetfile, $cfg_thumb, $cfg_watermarktext, $photo_waterpos, $photo_diaphaneity, $photo_wheight, $photo_wwidth, $cfg_watermarktype, $photo_marktrans, $trueMarkimg, $attach); | |||
| } | |||
| //析构函数 | |||
| function __construct($targetfile, $cfg_thumb, $cfg_watermarktext, $photo_waterpos, $photo_diaphaneity, $photo_wheight, $photo_wwidth, $cfg_watermarktype, $photo_marktrans, $trueMarkimg, $attach = array()) | |||
| { | |||
| @@ -43,8 +41,6 @@ class image | |||
| $this->targetfile = $targetfile; | |||
| $this->attachinfo = @getimagesize($targetfile); | |||
| $this->attach = $attach; | |||
| switch ($this->attachinfo['mime']) { | |||
| case 'image/jpeg': | |||
| $this->imagecreatefromfunc = function_exists('imagecreatefromjpeg') ? 'imagecreatefromjpeg' : ''; | |||
| @@ -58,8 +54,7 @@ class image | |||
| $this->imagecreatefromfunc = function_exists('imagecreatefrompng') ? 'imagecreatefrompng' : ''; | |||
| $this->imagefunc = function_exists('imagepng') ? 'imagepng' : ''; | |||
| break; | |||
| } //为空则匹配类型的函数不存在 | |||
| }//为空则匹配类型的函数不存在 | |||
| $this->attach['size'] = empty($this->attach['size']) ? @filesize($targetfile) : $this->attach['size']; | |||
| if ($this->attachinfo['mime'] == 'image/gif') { | |||
| $fp = fopen($targetfile, 'rb'); | |||
| @@ -68,7 +63,6 @@ class image | |||
| $this->animatedgif = strpos($targetfilecontent, 'NETSCAPE2.0') === false ? 0 : 1; | |||
| } | |||
| } | |||
| /** | |||
| * 生成缩略图 | |||
| * | |||
| @@ -81,13 +75,11 @@ class image | |||
| function thumb($thumbwidth, $thumbheight, $preview = 0) | |||
| { | |||
| $this->thumb_gd($thumbwidth, $thumbheight, $preview); | |||
| if ($this->thumbstatus == 2 && $this->watermarkstatus) { | |||
| $this->image($this->targetfile, $this->attach); | |||
| $this->attach['size'] = filesize($this->targetfile); | |||
| } | |||
| } | |||
| /** | |||
| * 图片水印 | |||
| * | |||
| @@ -102,7 +94,6 @@ class image | |||
| } | |||
| $this->watermark_gd($preview); | |||
| } | |||
| /** | |||
| * 使用gd生成缩略图 | |||
| * | |||
| @@ -114,7 +105,6 @@ class image | |||
| */ | |||
| function thumb_gd($thumbwidth, $thumbheight, $preview = 0) | |||
| { | |||
| if ($this->thumbstatus && function_exists('imagecreatetruecolor') && function_exists('imagecopyresampled') && function_exists('imagejpeg')) { | |||
| $imagecreatefromfunc = $this->imagecreatefromfunc; | |||
| $imagefunc = $this->thumbstatus == 1 ? 'imagejpeg' : $this->imagefunc; | |||
| @@ -142,7 +132,6 @@ class image | |||
| } | |||
| } | |||
| } | |||
| /** | |||
| * 使用gd进行水印 | |||
| * | |||
| @@ -176,7 +165,6 @@ class image | |||
| if (($this->watermarktype < 2 && is_readable($watermark_file) || $this->watermarktype == 2) && $wmwidth > 10 && $wmheight > 10 && !$this->animatedgif) { | |||
| switch ($this->watermarkstatus) { | |||
| case 1: | |||
| $x = +5; | |||
| $y = +5; | |||
| break; | |||
| @@ -40,6 +40,5 @@ if (function_exists("imagecreatefromwbmp") && function_exists("imagewbmp")) { | |||
| $cfg_photo_typenames[] = "image/wbmp"; | |||
| $cfg_photo_support .= "WBMP "; | |||
| } | |||
| //引入图像处理小助手 | |||
| helper('image'); | |||
| helper('image'); | |||
| @@ -32,13 +32,11 @@ function CheckUserID($uid, $msgtitle = '用户名', $ckhas = TRUE) | |||
| if ($cfg_md_idurl == 'Y' && preg_match("/[^a-z0-9]/i", $uid)) { | |||
| return $msgtitle.'必须由英文字母或数字组成'; | |||
| } | |||
| if ($cfg_soft_lang == 'utf-8') { | |||
| $ck_uid = utf82gb($uid); | |||
| } else { | |||
| $ck_uid = $uid; | |||
| } | |||
| for ($i = 0; isset($ck_uid[$i]); $i++) { | |||
| if (ord($ck_uid[$i]) > 0x80) { | |||
| if (isset($ck_uid[$i + 1]) && ord($ck_uid[$i + 1]) > 0x40) { | |||
| @@ -58,7 +56,6 @@ function CheckUserID($uid, $msgtitle = '用户名', $ckhas = TRUE) | |||
| } | |||
| return 'ok'; | |||
| } | |||
| /** | |||
| * 检查用户是否被禁言 | |||
| * | |||
| @@ -79,7 +76,6 @@ function CheckNotAllow() | |||
| exit(); | |||
| } | |||
| } | |||
| function FormatUsername($username) | |||
| { | |||
| $username = str_replace("`", "‘", $username); | |||
| @@ -90,7 +86,6 @@ function FormatUsername($username) | |||
| $username = str_replace(")", ")", $username); | |||
| return addslashes($username); | |||
| } | |||
| /** | |||
| * 网站会员登录类 | |||
| * | |||
| @@ -119,7 +114,6 @@ class MemberLogin | |||
| var $M_JoinTime; | |||
| var $M_Honor = ''; | |||
| var $memberCache = 'memberlogin'; | |||
| //php5构造函数 | |||
| function __construct($kptime = -1, $cache = FALSE) | |||
| { | |||
| @@ -149,7 +143,6 @@ class MemberLogin | |||
| } else { | |||
| $this->fields = $dsql->GetOne("SELECT * FROM `#@__member` WHERE mid='{$this->M_ID}' "); | |||
| } | |||
| if (is_array($this->fields)) { | |||
| //间隔一小时更新一次用户登录时间 | |||
| if (time() - $this->M_LoginTime > 3600) { | |||
| @@ -183,12 +176,10 @@ class MemberLogin | |||
| } | |||
| } | |||
| } | |||
| function MemberLogin($kptime = -1) | |||
| { | |||
| $this->__construct($kptime); | |||
| } | |||
| /** | |||
| * 删除缓存,每次登录时和在修改用户资料的地方会清除 | |||
| * | |||
| @@ -200,7 +191,6 @@ class MemberLogin | |||
| { | |||
| DelCache($this->memberCache, $mid); | |||
| } | |||
| /** | |||
| * 判断会员是否到期 | |||
| * | |||
| @@ -212,12 +202,10 @@ class MemberLogin | |||
| $nowtime = time(); | |||
| $mhasDay = $this->M_ExpTime - ceil(($nowtime - $this->M_UpTime) / 3600 / 24) + 1; | |||
| if ($mhasDay <= 0) { | |||
| $dsql->ExecuteNoneQuery("UPDATE `#@__member` SET uptime='0',exptime='0', | |||
| rank='$cfg_mb_rank' WHERE mid='".$this->fields['mid']."';"); | |||
| $dsql->ExecuteNoneQuery("UPDATE `#@__member` SET uptime='0',exptime='0',rank='$cfg_mb_rank' WHERE mid='".$this->fields['mid']."';"); | |||
| } | |||
| return $mhasDay; | |||
| } | |||
| /** | |||
| * 退出cookie的会话 | |||
| * | |||
| @@ -227,7 +215,6 @@ class MemberLogin | |||
| { | |||
| $this->ResetUser(); | |||
| } | |||
| /** | |||
| * 验证用户是否已经登录 | |||
| * | |||
| @@ -238,7 +225,6 @@ class MemberLogin | |||
| if ($this->M_ID > 0) return TRUE; | |||
| else return FALSE; | |||
| } | |||
| /** | |||
| * 检测用户上传空间 | |||
| * | |||
| @@ -251,7 +237,6 @@ class MemberLogin | |||
| $row = $dsql->GetOne("SELECT sum(filesize) AS fs FROM `#@__uploads` WHERE mid='$uid'; "); | |||
| return $row['fs']; | |||
| } | |||
| /** | |||
| * 检查用户空间信息 | |||
| * | |||
| @@ -268,7 +253,6 @@ class MemberLogin | |||
| exit(); | |||
| } | |||
| } | |||
| /** | |||
| * 更新用户信息统计表 | |||
| * | |||
| @@ -294,12 +278,10 @@ class MemberLogin | |||
| } | |||
| } | |||
| $inquery = "INSERT INTO `#@__member_tj` (`mid`,`article`,`album`,`archives`,`homecount`,`pagecount`,`feedback`,`friend`,`stow`) | |||
| VALUES ('$mid','$article','$album','$archives','$homecount','$pagecount','$feedback','$friend','$stow'); "; | |||
| VALUES ('$mid','$article','$album','$archives','$homecount','$pagecount','$feedback','$friend','$stow'); "; | |||
| $dsql->ExecuteNoneQuery("Delete From `#@__member_tj` where mid='$mid' "); | |||
| $dsql->ExecuteNoneQuery($inquery); | |||
| } | |||
| // | |||
| /** | |||
| * 重置用户信息 | |||
| * | |||
| @@ -325,7 +307,6 @@ class MemberLogin | |||
| DropCookie('DedeUserID'); | |||
| DropCookie('DedeLoginTime'); | |||
| } | |||
| /** | |||
| * 获取整数值 | |||
| * | |||
| @@ -338,7 +319,6 @@ class MemberLogin | |||
| $fnum = preg_replace("/[^0-9\.]/", '', $fnum); | |||
| return $fnum; | |||
| } | |||
| /** | |||
| * 用户登录 | |||
| * 把登录密码转为指定长度md5数据 | |||
| @@ -362,7 +342,6 @@ class MemberLogin | |||
| return md5($pwd); | |||
| } | |||
| } | |||
| /** | |||
| * 把数据库密码转为特定长度 | |||
| * 如果数据库密码是明文的,本程序不支持 | |||
| @@ -391,7 +370,6 @@ class MemberLogin | |||
| } | |||
| } | |||
| } | |||
| /** | |||
| * 检查用户是否合法 | |||
| * | |||
| @@ -403,16 +381,13 @@ class MemberLogin | |||
| function CheckUser(&$loginuser, $loginpwd) | |||
| { | |||
| global $dsql; | |||
| //检测用户名的合法性 | |||
| $rs = CheckUserID($loginuser, '用户名', FALSE); | |||
| //用户名不正确时返回验证错误,原登录名通过引用返回错误提示信息 | |||
| if ($rs != 'ok') { | |||
| $loginuser = $rs; | |||
| return '0'; | |||
| } | |||
| //matt=10 是管理员关连的前台帐号,为了安全起见,这个帐号只能从后台登录,不能直接从前台登录 | |||
| $row = $dsql->GetOne("SELECT mid,matt,pwd,logintime FROM `#@__member` WHERE userid LIKE '$loginuser' "); | |||
| if (is_array($row)) { | |||
| @@ -431,7 +406,6 @@ class MemberLogin | |||
| return 0; | |||
| } | |||
| } | |||
| /** | |||
| * 保存用户cookie | |||
| * | |||
| @@ -460,7 +434,6 @@ class MemberLogin | |||
| PutCookie('DedeLoginTime', $this->M_LoginTime); | |||
| } | |||
| } | |||
| /** | |||
| * 获得会员目前的状态 | |||
| * | |||
| @@ -10,7 +10,6 @@ if (!defined('DEDEINC')) exit('dedebiz'); | |||
| * @link https://www.dedebiz.com | |||
| */ | |||
| require_once(DEDEINC."/channelunit.func.php"); | |||
| /** | |||
| * 网站地图(sitemap类) | |||
| * | |||
| @@ -23,7 +22,6 @@ class SiteMap | |||
| var $dsql; | |||
| var $artDir; | |||
| var $baseDir; | |||
| //php5构造函数 | |||
| function __construct() | |||
| { | |||
| @@ -33,17 +31,14 @@ class SiteMap | |||
| $this->idArrary = ""; | |||
| $this->dsql = $GLOBALS['dsql']; | |||
| } | |||
| function SiteMap() | |||
| { | |||
| $this->__construct(); | |||
| } | |||
| //清理类 | |||
| function Close() | |||
| { | |||
| } | |||
| /** | |||
| * 获取网站地图 | |||
| * | |||
| @@ -68,17 +63,9 @@ class SiteMap | |||
| } | |||
| $mapString .= "<div class=\"linkbox\">\r\n<h3><a href='$typelink'>".$row->typename."</a></h3>"; | |||
| $mapString .= "\t<ul class=\"f6\">\t\t\r".$this->LogicListAllSunType($row->id, $maptype)."\t\n</ul></div>\r\n"; | |||
| /* | |||
| $mapString .= "<tr><td width='17%' align='center' bgcolor='#FAFEF1'>"; | |||
| $mapString .= "<a href='$typelink'><b>".$row->typename."</b></a>"; | |||
| $mapString .= "</td><td width='83%' bgcolor='#FFFFFF'>"; | |||
| $mapString .= $this->LogicListAllSunType($row->id,$maptype); | |||
| $mapString .= "</td></tr>"; | |||
| */ | |||
| } | |||
| return $mapString; | |||
| } | |||
| /** | |||
| * 获得子类目的递归调用 | |||
| * | |||
| @@ -108,4 +95,4 @@ class SiteMap | |||
| } | |||
| return $mapString; | |||
| } | |||
| } | |||
| } | |||
| @@ -10,7 +10,6 @@ if (!defined('DEDEINC')) exit('dedebiz'); | |||
| * @link https://www.dedebiz.com | |||
| */ | |||
| session_start(); | |||
| /** | |||
| * 检验用户是否有权使用某功能,这个函数是一个回值函数 | |||
| * CheckPurview函数只是对他回值的一个处理过程 | |||
| @@ -45,7 +44,6 @@ function TestPurview($n) | |||
| } | |||
| return $rs; | |||
| } | |||
| /** | |||
| * 对权限检测后返回操作对话框 | |||
| * | |||
| @@ -60,7 +58,6 @@ function CheckPurview($n) | |||
| exit(); | |||
| } | |||
| } | |||
| /** | |||
| * 是否没权限限制(超级管理员) | |||
| * | |||
| @@ -77,9 +74,7 @@ function TestAdmin() | |||
| return FALSE; | |||
| } | |||
| } | |||
| $DedeUserCatalogs = array(); | |||
| /** | |||
| * 检测用户是否有权限操作某栏目 | |||
| * | |||
| @@ -100,7 +95,6 @@ function CheckCatalog($cid, $msg) | |||
| } | |||
| return TRUE; | |||
| } | |||
| /** | |||
| * 发布文档临时附件信息缓存、发文档前先清空附件信息 | |||
| * 发布文档时涉及的附件保存到缓存里,完成后把它与文档关连 | |||
| @@ -128,7 +122,6 @@ function AddMyAddon($fid, $filename) | |||
| fwrite($fp, "\$maNum = $maNum;\r\n"); | |||
| fclose($fp); | |||
| } | |||
| /** | |||
| * 清理附件,如果关连的文档ID,先把上一批附件传给这个文档ID | |||
| * | |||
| @@ -146,7 +139,6 @@ function ClearMyAddon($aid = 0, $title = '') | |||
| if (!file_exists($cacheFile)) { | |||
| return; | |||
| } | |||
| //把附件与文档关连 | |||
| if (!empty($aid)) { | |||
| include($cacheFile); | |||
| @@ -160,7 +152,6 @@ function ClearMyAddon($aid = 0, $title = '') | |||
| } | |||
| @unlink($cacheFile); | |||
| } | |||
| /** | |||
| * 登录类 | |||
| * | |||
| @@ -184,7 +175,6 @@ class userLogin | |||
| var $keepUserPurviewTag = 'dede_admin_purview'; | |||
| var $keepAdminStyleTag = 'dede_admin_style'; | |||
| var $adminStyle = 'DedeBIZ'; | |||
| //php5构造函数 | |||
| function __construct($admindir = '') | |||
| { | |||
| @@ -197,19 +187,16 @@ class userLogin | |||
| $this->userPurview = $_SESSION[$this->keepUserPurviewTag]; | |||
| $this->adminStyle = $_SESSION[$this->keepAdminStyleTag]; | |||
| } | |||
| if ($admindir != '') { | |||
| $this->adminDir = $admindir; | |||
| } else { | |||
| $this->adminDir = $admin_path; | |||
| } | |||
| } | |||
| function userLogin($admindir = '') | |||
| { | |||
| $this->__construct($admindir); | |||
| } | |||
| /** | |||
| * 检验用户是否正确 | |||
| * | |||
| @@ -221,7 +208,6 @@ class userLogin | |||
| function checkUser($username, $userpwd) | |||
| { | |||
| global $dsql; | |||
| //只允许用户名和密码用0-9,a-z,A-Z,'@','_','.','-'这些字符 | |||
| $this->userName = preg_replace("/[^0-9a-zA-Z_@!\.-]/", '', $username); | |||
| $this->userPwd = preg_replace("/[^0-9a-zA-Z_@!\.-]/", '', $userpwd); | |||
| @@ -247,7 +233,6 @@ class userLogin | |||
| return 1; | |||
| } | |||
| } | |||
| /** | |||
| * 保持用户的会话状态 | |||
| * | |||
| @@ -259,36 +244,26 @@ class userLogin | |||
| if ($this->userID != '' && $this->userType != '') { | |||
| global $admincachefile, $adminstyle; | |||
| if (empty($adminstyle)) $adminstyle = 'DedeBIZ'; | |||
| @session_register($this->keepUserIDTag); | |||
| $_SESSION[$this->keepUserIDTag] = $this->userID; | |||
| @session_register($this->keepUserTypeTag); | |||
| $_SESSION[$this->keepUserTypeTag] = $this->userType; | |||
| @session_register($this->keepUserChannelTag); | |||
| $_SESSION[$this->keepUserChannelTag] = $this->userChannel; | |||
| @session_register($this->keepUserNameTag); | |||
| $_SESSION[$this->keepUserNameTag] = $this->userName; | |||
| @session_register($this->keepUserPurviewTag); | |||
| $_SESSION[$this->keepUserPurviewTag] = $this->userPurview; | |||
| @session_register($this->keepAdminStyleTag); | |||
| $_SESSION[$this->keepAdminStyleTag] = $adminstyle; | |||
| PutCookie('DedeUserID', $this->userID, 3600 * 24, '/'); | |||
| PutCookie('DedeLoginTime', time(), 3600 * 24, '/'); | |||
| $this->ReWriteAdminChannel(); | |||
| return 1; | |||
| } else { | |||
| return -1; | |||
| } | |||
| } | |||
| /** | |||
| * 重写用户权限频道 | |||
| * | |||
| @@ -323,8 +298,6 @@ class userLogin | |||
| fwrite($fp, '?'.'>'); | |||
| fclose($fp); | |||
| } | |||
| // | |||
| /** | |||
| * 结束用户的会话状态 | |||
| * | |||
| @@ -344,7 +317,6 @@ class userLogin | |||
| DropCookie('DedeLoginTime'); | |||
| $_SESSION = array(); | |||
| } | |||
| /** | |||
| * 获得用户管理频道的值 | |||
| * | |||
| @@ -359,7 +331,6 @@ class userLogin | |||
| return ''; | |||
| } | |||
| } | |||
| /** | |||
| * 获得用户的权限值 | |||
| * | |||
| @@ -374,7 +345,6 @@ class userLogin | |||
| return -1; | |||
| } | |||
| } | |||
| /** | |||
| * 获取用户权限值 | |||
| * | |||
| @@ -385,7 +355,6 @@ class userLogin | |||
| { | |||
| return $this->getUserType(); | |||
| } | |||
| /** | |||
| * 获得用户的ID | |||
| * | |||
| @@ -400,7 +369,6 @@ class userLogin | |||
| return -1; | |||
| } | |||
| } | |||
| /** | |||
| * 获得用户的笔名 | |||
| * | |||
| @@ -415,7 +383,6 @@ class userLogin | |||
| return -1; | |||
| } | |||
| } | |||
| /** | |||
| * 用户权限表 | |||
| * | |||
| @@ -427,7 +394,6 @@ class userLogin | |||
| return $this->userPurview; | |||
| } | |||
| } | |||
| /** | |||
| * 获得某id的所有下级id | |||
| * | |||
| @@ -448,7 +414,6 @@ function GetSonIdsUL($id, $channel = 0, $addthis = TRUE) | |||
| $rquery = join(',', $GLOBALS['idArray']); | |||
| return $rquery; | |||
| } | |||
| /** | |||
| * 递归逻辑 | |||
| * | |||
| @@ -469,4 +434,4 @@ function GetSonIdsLogicUL($id, $sArr, $channel = 0, $addthis = FALSE) | |||
| GetSonIdsLogicUL($k, $sArr, $channel, TRUE); | |||
| } | |||
| } | |||
| } | |||
| } | |||
| @@ -9,7 +9,7 @@ | |||
| <script src="{dede:global.cfg_cmsurl/}/static/js/jquery.min.js"></script> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/bootstrap.min.css"> | |||
| <link href="{dede:global.cfg_cmsurl/}/static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/dede.css"> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/style.css"> | |||
| <link rel="shortcut icon" href="{dede:global.cfg_cmsurl/}/static/img/favicon.png"> | |||
| <title>{dede:field.title/}_{dede:global.cfg_webname/}</title> | |||
| <meta name="keywords" content="{dede:field.keywords/}" /> | |||
| @@ -10,7 +10,7 @@ | |||
| <script src="{dede:global.cfg_cmsurl/}/static/js/bootstrap.bundle.js"></script> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/bootstrap.min.css"> | |||
| <link href="{dede:global.cfg_cmsurl/}/static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/dede.css"> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/style.css"> | |||
| <link rel="shortcut icon" href="{dede:global.cfg_cmsurl/}/static/img/favicon.png"> | |||
| <title>{dede:field.title/}_{dede:global.cfg_webname/}</title> | |||
| <meta name="keywords" content="{dede:field.keywords/}" /> | |||
| @@ -10,7 +10,7 @@ | |||
| <script src="{dede:global.cfg_cmsurl/}/static/js/bootstrap.bundle.js"></script> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/bootstrap.min.css"> | |||
| <link href="{dede:global.cfg_cmsurl/}/static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/dede.css"> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/style.css"> | |||
| <link rel="shortcut icon" href="{dede:global.cfg_cmsurl/}/static/img/favicon.png"> | |||
| <title>{dede:field.title/}_{dede:global.cfg_webname/}</title> | |||
| <meta name="keywords" content="{dede:field.keywords/}" /> | |||
| @@ -10,7 +10,7 @@ | |||
| <script src="{dede:global.cfg_cmsurl/}/static/js/bootstrap.bundle.js"></script> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/bootstrap.min.css"> | |||
| <link href="{dede:global.cfg_cmsurl/}/static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/dede.css"> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/style.css"> | |||
| <link rel="shortcut icon" href="{dede:global.cfg_cmsurl/}/static/img/favicon.png"> | |||
| <title>{dede:field.title/}_{dede:global.cfg_webname/}</title> | |||
| <meta name="keywords" content="{dede:field.keywords/}" /> | |||
| @@ -9,7 +9,7 @@ | |||
| <script src="{dede:global.cfg_cmsurl/}/static/js/jquery.min.js"></script> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/bootstrap.min.css"> | |||
| <link href="{dede:global.cfg_cmsurl/}/static/font-awesome/css/font-awesome.min.css" rel="stylesheet"> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/dede.css"> | |||
| <link rel="stylesheet" href="{dede:global.cfg_cmsurl/}/static/css/style.css"> | |||
| <link rel="shortcut icon" href="{dede:global.cfg_cmsurl/}/static/img/favicon.png"> | |||
| <title>{dede:field.title/}_{dede:global.cfg_webname/}</title> | |||
| <meta name="keywords" content="{dede:field.keywords/}" /> | |||