| @@ -62,6 +62,8 @@ a{text-decoration:none!important} | |||||
| function ReturnValue(reimg) { | function ReturnValue(reimg) { | ||||
| if (window.opener.document.<?php echo $f ?> != null) { | if (window.opener.document.<?php echo $f ?> != null) { | ||||
| window.opener.document.<?php echo $f ?>.value = reimg; | window.opener.document.<?php echo $f ?>.value = reimg; | ||||
| window.close(); | |||||
| return | |||||
| } | } | ||||
| var funcNum = <?php echo isset($CKEditorFuncNum) ? $CKEditorFuncNum : 1; ?>; | var funcNum = <?php echo isset($CKEditorFuncNum) ? $CKEditorFuncNum : 1; ?>; | ||||
| if (window.opener.CKEDITOR != null && funcNum != 1) { | if (window.opener.CKEDITOR != null && funcNum != 1) { | ||||
| @@ -14,6 +14,26 @@ function ShowWaitDiv() { | |||||
| $DE('loaddiv').style.display = 'block'; | $DE('loaddiv').style.display = 'block'; | ||||
| return true; | return true; | ||||
| } | } | ||||
| function DedeCopyToClipboard(text) { | |||||
| if (navigator.clipboard) { | |||||
| navigator.clipboard.writeText(text); | |||||
| } else { | |||||
| var textarea = document.createElement('textarea'); | |||||
| document.body.appendChild(textarea); | |||||
| // 隐藏此输入框 | |||||
| textarea.style.position = 'fixed'; | |||||
| textarea.style.clip = 'rect(0 0 0 0)'; | |||||
| textarea.style.top = '10px'; | |||||
| textarea.style.display = 'none'; | |||||
| textarea.value = text; | |||||
| textarea.select(); | |||||
| document.execCommand('copy', true); | |||||
| document.body.removeChild(textarea); | |||||
| } | |||||
| } | |||||
| function CopySystemInfo(txt) { | |||||
| DedeCopyToClipboard(txt); | |||||
| } | |||||
| $(function () { | $(function () { | ||||
| $.get("index_testenv.php", function (data) { | $.get("index_testenv.php", function (data) { | ||||
| if (data !== '') { | if (data !== '') { | ||||
| @@ -69,7 +69,7 @@ table.stattable td{padding:.6rem;border-bottom:1px solid #dee2e6;text-align:righ | |||||
| </div> | </div> | ||||
| <div class="col-md-6 mt-3 mb-3 updatenews"> | <div class="col-md-6 mt-3 mb-3 updatenews"> | ||||
| <div class="card"> | <div class="card"> | ||||
| <div class="card-header"><i class="fa fa-gear"></i> 系统信息</div> | |||||
| <div class="card-header"><a href="javascript:CopySystemInfo(`DedeBIZ:操作系统:<?php echo PHP_OS; ?>|Web服务器:<?php echo $_SERVER['SERVER_SOFTWARE']; ?>|PHP版本:<?php echo @phpversion(); ?>|数据库版本:<?php echo $dsql->GetVersion(); ?>`);"><i class="fa fa-gear"></i></a> 系统信息</div> | |||||
| <div class="card-body"> | <div class="card-body"> | ||||
| <div id="updateinfos"> | <div id="updateinfos"> | ||||
| <?php echo "<iframe name='stafrm' src='{$offUrl}&uptime={$oktime}' frameborder='0' id='stafrm' style='width:98%;height:70px;padding:.6rem'></iframe>"; ?> | <?php echo "<iframe name='stafrm' src='{$offUrl}&uptime={$oktime}' frameborder='0' id='stafrm' style='width:98%;height:70px;padding:.6rem'></iframe>"; ?> | ||||
| @@ -205,7 +205,7 @@ function ShowMsg($msg, $gourl, $onlymsg = 0, $limittime = 0) | |||||
| global $cfg_soft_lang, $cfg_cmsurl; | global $cfg_soft_lang, $cfg_cmsurl; | ||||
| if(empty($GLOBALS['cfg_plus_dir'])) $GLOBALS['cfg_plus_dir'] = '..'; | if(empty($GLOBALS['cfg_plus_dir'])) $GLOBALS['cfg_plus_dir'] = '..'; | ||||
| $htmlhead = "<html><head><meta charset='utf-8'><title>提示信息</title><meta name='viewport' content='width=device-width,initial-scale=1'><base target='_self'></head>"; | $htmlhead = "<html><head><meta charset='utf-8'><title>提示信息</title><meta name='viewport' content='width=device-width,initial-scale=1'><base target='_self'></head>"; | ||||
| $htmlhead .= "<body>".(isset($GLOBALS['ucsynlogin']) ? $GLOBALS['ucsynlogin'] : '')."<center><script>"; | |||||
| $htmlhead .= "<body><center><script>"; | |||||
| $htmlfoot = "</script></center></body></html>"; | $htmlfoot = "</script></center></body></html>"; | ||||
| $litime = ($limittime == 0 ? 1000 : $limittime); | $litime = ($limittime == 0 ? 1000 : $limittime); | ||||
| $func = ''; | $func = ''; | ||||
| @@ -57,7 +57,31 @@ class DedeStatistics { | |||||
| return <<<EOT | return <<<EOT | ||||
| (function() { | (function() { | ||||
| let u = '{$url}'; | let u = '{$url}'; | ||||
| fetch(u); | |||||
| var ms_ie = false; | |||||
| var ua = window.navigator.userAgent; | |||||
| if ((ua.indexOf('MSIE ') > -1) || (ua.indexOf('Trident/') > -1)) { | |||||
| ms_ie = true; | |||||
| } | |||||
| if (ms_ie) { | |||||
| var xhr; | |||||
| if (window.XMLHttpRequest) { | |||||
| xhr = new XMLHttpRequest(); | |||||
| } else if (window.ActiveXObject) { // IE | |||||
| try { | |||||
| xhr = new ActiveXObject('Msxml2.XMLHTTP'); | |||||
| } catch (e) { | |||||
| try { | |||||
| xhr = new ActiveXObject('Microsoft.XMLHTTP'); | |||||
| } catch (e) {} | |||||
| } | |||||
| } | |||||
| if (xhr) { | |||||
| xhr.open('GET', u, true); | |||||
| xhr.send(null); | |||||
| } | |||||
| } else { | |||||
| fetch(u); | |||||
| } | |||||
| })(); | })(); | ||||
| EOT; | EOT; | ||||
| } | } | ||||