From bd4ae7a191bdb2a712b1989d839ac64be4faab0b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=B0=8F=E8=83=A1?= <3203164629@qq.com>
Date: Tue, 15 Oct 2024 13:08:16 +0800
Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
admin/appmarket/cp.php | 2 +-
admin/appmarket/list.php | 2 +-
core/function/function_core.php | 2 +-
dzz/system/template/filelist.htm | 6 +-
dzz/system/template/fileselection/index.htm | 6 +-
dzz/system/template/positionlist.htm | 6 +-
dzz/system/template/selorguser.htm | 2 +-
static/js/common.js | 2887 ++++++++++++++++++-
8 files changed, 2899 insertions(+), 14 deletions(-)
diff --git a/admin/appmarket/cp.php b/admin/appmarket/cp.php
index 6029352..b32d6cf 100644
--- a/admin/appmarket/cp.php
+++ b/admin/appmarket/cp.php
@@ -213,7 +213,7 @@ elseif ($do == 'install') {//安装应用
if(empty($apparray['app']['app_path'])) $apparray['app']['app_path']=$dir;
$filename = $apparray['app']['extra']['installfile'];
- $request_uri = MOD_NAME;
+ $request_uri = MOD_URL;
if (!empty($filename) && preg_match('/^[\w\.]+$/', $filename)) {
$filename = DZZ_ROOT . './'.$dir.'/' . $appname . '/' . $filename;
if (file_exists($filename)) {
diff --git a/admin/appmarket/list.php b/admin/appmarket/list.php
index bf58d40..4e5bf40 100644
--- a/admin/appmarket/list.php
+++ b/admin/appmarket/list.php
@@ -12,7 +12,7 @@ if (!defined('IN_DZZ') || !defined('IN_ADMIN')) {
include libfile('function/admin');
include libfile('function/organization');
$do = empty($_GET['do']) ? 'available' : trim($_GET['do']);
-$refer = urlencode(MOD_URL. '&op=list&do=' . $do);
+$refer = urlencode(MOD_URL . '&op=list&do=' . $do);
$grouptitle = array('0' => lang('all'), '-1' => lang('visitors_visible'), '1' => lang('members_available'), '2' => lang('section_administrators_available'), '3' => lang('system_administrators_available'));
$list = array();
$op=$_GET['op'];
diff --git a/core/function/function_core.php b/core/function/function_core.php
index dfe6b33..c56c875 100644
--- a/core/function/function_core.php
+++ b/core/function/function_core.php
@@ -381,7 +381,7 @@ function authcode($string, $operation = 'DECODE', $key = '', $expiry = 0, $ckey_
}
if ($operation == 'DECODE') {
- if ((substr($result, 0, 10) == 0 || substr($result, 0, 10) - time() > 0) && substr($result, 10, 16) == substr(md5(substr($result, 26) . $keyb), 0, 16)) {
+ if ((substr($result, 0, 10) == 0 || substr($result, 0, 10) - time() > 0) && substr($result, 10, 16) === substr(md5(substr($result, 26) . $keyb), 0, 16)) {
return substr($result, 26);
} else {
return '';
diff --git a/dzz/system/template/filelist.htm b/dzz/system/template/filelist.htm
index ad0555b..650294a 100644
--- a/dzz/system/template/filelist.htm
+++ b/dzz/system/template/filelist.htm
@@ -296,10 +296,10 @@ function submitdata(){
}else{
$.post(MOD_URL+'&op=positionlist&do=geffolderinfo',{'fid':fid},function(data){
try{if(typeof parent.showWindow_callback == 'function') parent.showWindow_callback(fid,data);}catch(e){}
- if(parent.$callback){
- try{ parent.$callback (fid,data);}catch(e){}
+ if(parent.{$callback}){
+ try{ parent.{$callback}(fid,data);}catch(e){}
}else{
- try{ opened.$callback (fid,data);}catch(e){}
+ try{ opened.{$callback}(fid,data);}catch(e){}
}
hide_window();
diff --git a/dzz/system/template/fileselection/index.htm b/dzz/system/template/fileselection/index.htm
index 7125c58..2dd8981 100644
--- a/dzz/system/template/fileselection/index.htm
+++ b/dzz/system/template/fileselection/index.htm
@@ -164,13 +164,13 @@ html, body{
parent.showWindow_callback(data,'$token');
}
}catch(e){}
- if (parent.$callback) {
+ if (parent.{$callback}) {
try{
- parent.$callback (data, '$token');
+ parent.{$callback}(data, '$token');
}catch(e){}
} else {
try{
- opened.$callback (data, '$token');
+ opened.{$callback}(data, '$token');
}catch(e){}
}
hide_window();
diff --git a/dzz/system/template/positionlist.htm b/dzz/system/template/positionlist.htm
index 7501527..ffb95d2 100644
--- a/dzz/system/template/positionlist.htm
+++ b/dzz/system/template/positionlist.htm
@@ -373,10 +373,10 @@
return false;
} else {
$.post(MOD_URL + '&op=positionlist&do=geffolderinfo', {'fid': fid}, function (data) {
- if (parent.$callback) {
- parent.$callback (fid, data);
+ if (parent.{$callback}) {
+ parent.{$callback}(fid, data);
} else {
- opened.$callback (fid, data);
+ opened.{$callback}(fid, data);
}
hide_window();
}, 'json')
diff --git a/dzz/system/template/selorguser.htm b/dzz/system/template/selorguser.htm
index c200551..0403238 100644
--- a/dzz/system/template/selorguser.htm
+++ b/dzz/system/template/selorguser.htm
@@ -208,7 +208,7 @@
}
});
try{
- $callback (ids,data,'$token');//ids:选中的id列表如:[g_1,125,g_32...],g_开头的标识是机构部门或群组
+ {$callback}(ids,data,'$token');//ids:选中的id列表如:[g_1,125,g_32...],g_开头的标识是机构部门或群组
}catch(e){};
hideWindow("$_GET['handlekey']");
return false;
diff --git a/static/js/common.js b/static/js/common.js
index 4d22fef..3d4bad9 100644
--- a/static/js/common.js
+++ b/static/js/common.js
@@ -6,4 +6,2889 @@
* @link http://www.dzzoffice.com
* @author zyx(zyx@dzz.cc)
*/
-var _header={init:function(e){_header.formhash=e},loging_close:function(){var e='您确定要注销登录?';showDialog(e,"confirm","",function(){jQuery.get("user.php?mod=login&op=logging&action=logout&formhash="+_header.formhash+"&t="+(new Date).getTime(),function(e){window.location.reload()})})},leftTopmenu:function(e,t){var n=document.documentElement.clientWidth;if(t||(t=jQuery(".bs-left-container").is(":visible")?"hide":"show"),"hide"===t)jQuery(".bs-left-container").hide(),jQuery(".left-drager").hide(),jQuery(".bs-main-container").css("marginLeft",0),jQuery(e).removeClass("leftTopmenu");else if("show"===t){jQuery(".bs-left-container").show();var i=jQuery(".bs-left-container").outerWidth(!0);i<20&&(i=20,jQuery(".bs-left-container").width(i),jQuery(".left-drager").css({left:i,cursor:"w-resize"})),jQuery(".left-drager").show(),jQuery(".bs-main-container").css("marginLeft",n<768?0:i),jQuery(e).addClass("leftTopmenu")}}},BROWSER={},USERAGENT=navigator.userAgent.toLowerCase();browserVersion({ie:"msie",edge:"edge",rv:"rv",firefox:"",chrome:"",opera:"",safari:"",mozilla:"",webkit:"",maxthon:"",qq:"qqbrowser",ie11:"trident"}),BROWSER.ie11?(BROWSER.ie=11,BROWSER.rv=11):BROWSER.rv=0,BROWSER.safari&&(BROWSER.firefox=!0),BROWSER.opera=BROWSER.opera?opera.version():0,HTMLNODE=document.getElementsByTagName("head")[0].parentNode,BROWSER.ie&&(BROWSER.iemode=parseInt(void 0!==document.documentMode?document.documentMode:BROWSER.ie),HTMLNODE.className="ie_all ie"+BROWSER.iemode);var CSSLOADED=[],JSLOADED=[],JSMENU=[];JSMENU.active=[],JSMENU.timer=[],JSMENU.drag=[],JSMENU.layer=0,JSMENU.zIndex={win:11200,menu:11300,dialog:11400,prompt:11500},JSMENU.float="";var CURRENTSTYPE=null,creditnotice=isUndefined(creditnotice)?"":creditnotice,cookiedomain=isUndefined(cookiedomain)?"":cookiedomain,cookiepath=isUndefined(cookiepath)?"":cookiepath,EXTRAFUNC=[],EXTRASTR="";EXTRAFUNC.showmenu=[];var USERABOUT_BOX=!0,USERCARDST=null,CLIPBOARDSWFDATA="",NOTICETITLE=[],NOTICECURTITLE=document.title,CurrentActive;function $C(e,t,n){var i=[];if(n=n||"*",(t=t||document).getElementsByClassName){var o=t.getElementsByClassName(e);if("*"!=n)for(var a=0,r=o.length;a99);return Math.max(e,0).toFixed(1)+["kB","MB","GB","TB","PB","EB"][t]}function trim(e){return(e+"").replace(/(\s+)$/g,"").replace(/^\s+/g,"")}function strlen(e){return BROWSER.ie&&-1!=e.indexOf("\n")?e.replace(/\r?\n/g,"_").length:e.length}function mb_strlen(e){for(var t=0,n=0;n255?"utf-8"==charset?3:2:1;return t}function mb_cutstr(e,t,n){var i=0,o="";t-=(n=""==n||n?n:"...").length;for(var a=0;a255?"utf-8"==charset?3:2:1)>t){o+=n;break}o+=e.substr(a,1)}return o}function strip_tags(e,t){t=(((t||"")+"").toLowerCase().match(/<[a-z][a-z0-9]*>/g)||[]).join("");return e.replace(/|<\?(?:php)?[\s\S]*?\?>/gi,"").replace(/<\/?([a-z][a-z0-9]*)\b[^>]*>/gi,function(e,n){return t.indexOf("<"+n.toLowerCase()+">")>-1?e:""})}function preg_replace(e,t,n,i){i=i||"ig";for(var o=e.length,a=0;a",'"'],["&","<",">",'"'],e)}function display(e){var t=document.getElementById(e);t.style.visibility?t.style.visibility="visible"==t.style.visibility?"hidden":"visible":t.style.display=""==t.style.display?"none":""}function checkall(e,t,n){n=n||"chkall";count=0;for(var i=0;in?i:document.cookie.length);return t?o:unescape(o)}function Ajax(e,t){var n=new Object;return n.loading=__lang.please_wait,n.recvType=e||"XML",n.waitId=t?document.getElementById(t):null,n.resultHandle=null,n.sendString="",n.targetUrl="",n.setLoading=function(e){null!=e&&(n.loading=e)},n.setRecvType=function(e){n.recvType=e},n.setWaitId=function(e){n.waitId="object"==typeof e?e:document.getElementById(e)},n.createXMLHttpRequest=function(){var e=!1;if(window.XMLHttpRequest)(e=new XMLHttpRequest).overrideMimeType&&e.overrideMimeType("text/xml");else if(window.ActiveXObject)for(var t=["Microsoft.XMLHTTP","MSXML.XMLHTTP","Microsoft.XMLHTTP","Msxml2.XMLHTTP.7.0","Msxml2.XMLHTTP.6.0","Msxml2.XMLHTTP.5.0","Msxml2.XMLHTTP.4.0","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP"],n=0;n
'+n.loading+"")},n.processHandle=function(){if(4==n.XMLHttpRequest.readyState&&200==n.XMLHttpRequest.status)if(n.waitId&&(n.waitId.style.display="none"),"HTML"==n.recvType)n.resultHandle(n.XMLHttpRequest.responseText,n);else if("XML"==n.recvType)n.XMLHttpRequest.responseXML&&n.XMLHttpRequest.responseXML.lastChild&&"parsererror"!=n.XMLHttpRequest.responseXML.lastChild.localName?n.resultHandle(n.XMLHttpRequest.responseXML.lastChild.firstChild.nodeValue,n):n.resultHandle(''+__lang.internal_error_unable_display_content+"",n);else if("JSON"==n.recvType){var e=null;try{e=new Function("return ("+n.XMLHttpRequest.responseText+")")()}catch(t){e=null}n.resultHandle(e,n)}},n.get=function(e,t){e=hostconvert(e),setTimeout(function(){n.showLoading()},250),n.targetUrl=e,n.XMLHttpRequest.onreadystatechange=n.processHandle,n.resultHandle=t;var i=isUndefined(i)?0:i;window.XMLHttpRequest?(n.XMLHttpRequest.open("GET",n.targetUrl),n.XMLHttpRequest.setRequestHeader("X-Requested-With","XMLHttpRequest"),n.XMLHttpRequest.send(null)):(n.XMLHttpRequest.open("GET",e,!0),n.XMLHttpRequest.setRequestHeader("X-Requested-With","XMLHttpRequest"),n.XMLHttpRequest.send())},n.post=function(e,t,i){e=hostconvert(e),setTimeout(function(){n.showLoading()},250),n.targetUrl=e,n.sendString=t,n.XMLHttpRequest.onreadystatechange=n.processHandle,n.resultHandle=i,n.XMLHttpRequest.open("POST",e),n.XMLHttpRequest.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),n.XMLHttpRequest.setRequestHeader("X-Requested-With","XMLHttpRequest"),n.XMLHttpRequest.send(n.sendString)},n.getJSON=function(e,t){n.setRecvType("JSON"),n.get(e+"&ajaxdata=json",t)},n.getHTML=function(e,t){n.setRecvType("HTML"),n.get(e+"&ajaxdata=html",t)},n}function getHost(e){var t="null";void 0!==e&&null!=e||(e=window.location.href);var n=e.match(/^\w+\:\/\/([^\/]*).*/);return void 0!==n&&null!=n&&(t=n[1]),t}function hostconvert(e){e.match(/^https?:\/\//)||(e=SITEURL+e);var t=getHost(e),n=getHost().toLowerCase();return t&&n!=t&&(e=e.replace(t,n)),e}function newfunction(e){for(var t=[],n=1;n]*?>([^\x00]*?)<\/script>/gi,n=[];n=t.exec(e);){var i=/