@@ -81,7 +81,7 @@ button+button{margin-left:10px} | |||||
function addList(files){ | function addList(files){ | ||||
var files_sum = files.length; | var files_sum = files.length; | ||||
var vDom = document.createDocumentFragment(); | var vDom = document.createDocumentFragment(); | ||||
for(let i=0;i<files_sum;i++){ | |||||
for (let i=0;i<files_sum;i++) { | |||||
let file = files[i]; | let file = files[i]; | ||||
if (!isFileImage(file)) { | if (!isFileImage(file)) { | ||||
alert("选择非图片文件无法上传") | alert("选择非图片文件无法上传") | ||||
@@ -119,10 +119,10 @@ button+button{margin-left:10px} | |||||
if (!(dropfiles.length>0)){return false;} | if (!(dropfiles.length>0)){return false;} | ||||
var exts=axupimgs.axupimgs_filetype.replace(/(\s)+/g,'').toLowerCase().split(','); | var exts=axupimgs.axupimgs_filetype.replace(/(\s)+/g,'').toLowerCase().split(','); | ||||
var files=[]; | var files=[]; | ||||
for( let file of dropfiles ){ | |||||
for ( let file of dropfiles ) { | |||||
ext = file.name.split('.'); | ext = file.name.split('.'); | ||||
ext = '.'+ext[ext.length-1]; | ext = '.'+ext[ext.length-1]; | ||||
for(let s of exts){ | |||||
for (let s of exts) { | |||||
if (s==ext){ | if (s==ext){ | ||||
files.push(file); | files.push(file); | ||||
break; | break; | ||||
@@ -7,7 +7,7 @@ if (BROWSER.safari) { | |||||
BROWSER.opera = BROWSER.opera ? opera.version() : 0; | BROWSER.opera = BROWSER.opera ? opera.version() : 0; | ||||
function browserVersion(types) { | function browserVersion(types) { | ||||
var other = 1; | var other = 1; | ||||
for(i in types) { | |||||
for (i in types) { | |||||
var v = types[i] ? types[i] : i; | var v = types[i] ? types[i] : i; | ||||
if (USERAGENT.indexOf(v) != -1) { | if (USERAGENT.indexOf(v) != -1) { | ||||
var re = new RegExp(v + '(\\/|\\s)([\\d\\.]+)', 'ig'); | var re = new RegExp(v + '(\\/|\\s)([\\d\\.]+)', 'ig'); | ||||
@@ -1,8 +1,7 @@ | |||||
function selAll() | function selAll() | ||||
{ | { | ||||
var celements = document.getElementsByName('aids[]'); | var celements = document.getElementsByName('aids[]'); | ||||
for(i=0;i<celements.length;i++) | |||||
{ | |||||
for (i=0;i<celements.length;i++) { | |||||
if (!celements[i].checked) celements[i].checked = true; | if (!celements[i].checked) celements[i].checked = true; | ||||
else celements[i].checked = false; | else celements[i].checked = false; | ||||
} | } | ||||
@@ -10,50 +9,43 @@ function selAll() | |||||
function noselAll() | function noselAll() | ||||
{ | { | ||||
var celements = document.getElementsByName('aids[]'); | var celements = document.getElementsByName('aids[]'); | ||||
for(i=0;i<celements.length;i++) | |||||
{ | |||||
if (celements[i].checked = true) | |||||
{ | |||||
for (i=0;i<celements.length;i++) { | |||||
if (celements[i].checked = true) { | |||||
celements[i].checked = false; | celements[i].checked = false; | ||||
} | } | ||||
} | } | ||||
} | } | ||||
function delkey() | function delkey() | ||||
{ | { | ||||
if (window.confirm("您确定要删除选定的关键字吗")) | |||||
{ | |||||
if (window.confirm("您确定要删除选定的关键字吗")) { | |||||
document.form3.dopost.value = 'del'; | document.form3.dopost.value = 'del'; | ||||
document.form3.submit(); | document.form3.submit(); | ||||
} | } | ||||
} | } | ||||
function diskey() | function diskey() | ||||
{ | { | ||||
if (window.confirm("您确定要禁用选定的关键字吗")) | |||||
{ | |||||
if (window.confirm("您确定要禁用选定的关键字吗")) { | |||||
document.form3.dopost.value = 'dis'; | document.form3.dopost.value = 'dis'; | ||||
document.form3.submit(); | document.form3.submit(); | ||||
} | } | ||||
} | } | ||||
function enakey() | function enakey() | ||||
{ | { | ||||
if (window.confirm("您确定要启用选定的关键字吗")) | |||||
{ | |||||
if (window.confirm("您确定要启用选定的关键字吗")) { | |||||
document.form3.dopost.value = 'ena'; | document.form3.dopost.value = 'ena'; | ||||
document.form3.submit(); | document.form3.submit(); | ||||
} | } | ||||
} | } | ||||
function urlkey() | function urlkey() | ||||
{ | { | ||||
if (window.confirm("您确定要更新选定的关键字的网址吗")) | |||||
{ | |||||
if (window.confirm("您确定要更新选定的关键字的网址吗")) { | |||||
document.form3.dopost.value = 'url'; | document.form3.dopost.value = 'url'; | ||||
document.form3.submit(); | document.form3.submit(); | ||||
} | } | ||||
} | } | ||||
function rankey() | function rankey() | ||||
{ | { | ||||
if (window.confirm("您确定要改变选定的关键字的频率吗")) | |||||
{ | |||||
if (window.confirm("您确定要改变选定的关键字的频率吗")) { | |||||
document.form3.dopost.value = 'ran'; | document.form3.dopost.value = 'ran'; | ||||
document.form3.submit(); | document.form3.submit(); | ||||
} | } | ||||
@@ -61,8 +53,7 @@ function rankey() | |||||
//批量删除搜多关键字 | //批量删除搜多关键字 | ||||
function delall() | function delall() | ||||
{ | { | ||||
if (window.confirm("您确定要删除选定的关键字吗")) | |||||
{ | |||||
if (window.confirm("您确定要删除选定的关键字吗")) { | |||||
document.form3.dopost.value = 'delall'; | document.form3.dopost.value = 'delall'; | ||||
document.form3.submit(); | document.form3.submit(); | ||||
} | } |
@@ -5,8 +5,7 @@ function viewArc(aid){ | |||||
function kwArc(aid){ | function kwArc(aid){ | ||||
var qstr=getCheckboxItem(); | var qstr=getCheckboxItem(); | ||||
if (aid==0) aid = getOneItem(); | if (aid==0) aid = getOneItem(); | ||||
if (qstr=='') | |||||
{ | |||||
if (qstr=='') { | |||||
ShowMsg('需要选择一个或多个文档'); | ShowMsg('需要选择一个或多个文档'); | ||||
return; | return; | ||||
} | } | ||||
@@ -28,8 +27,7 @@ function checkArc(aid){ | |||||
} | } | ||||
function moveArc(e, obj, cid){ | function moveArc(e, obj, cid){ | ||||
var qstr=getCheckboxItem(); | var qstr=getCheckboxItem(); | ||||
if (qstr=='') | |||||
{ | |||||
if (qstr=='') { | |||||
ShowMsg('需要选择一个或多个文档'); | ShowMsg('需要选择一个或多个文档'); | ||||
return; | return; | ||||
} | } | ||||
@@ -45,8 +43,7 @@ function cAtts(jname, e, obj) | |||||
{ | { | ||||
var qstr=getCheckboxItem(); | var qstr=getCheckboxItem(); | ||||
var screeheight = document.body.clientHeight + 20; | var screeheight = document.body.clientHeight + 20; | ||||
if (qstr=='') | |||||
{ | |||||
if (qstr=='') { | |||||
ShowMsg('需要选择一个或多个文档'); | ShowMsg('需要选择一个或多个文档'); | ||||
return; | return; | ||||
} | } | ||||
@@ -68,7 +65,7 @@ function getCheckboxItem() | |||||
{ | { | ||||
var allSel=""; | var allSel=""; | ||||
if (document.form2.arcID.value) return document.form2.arcID.value; | if (document.form2.arcID.value) return document.form2.arcID.value; | ||||
for(i=0;i<document.form2.arcID.length;i++) | |||||
for (i=0;i<document.form2.arcID.length;i++) | |||||
{ | { | ||||
if (document.form2.arcID[i].checked) | if (document.form2.arcID[i].checked) | ||||
{ | { | ||||
@@ -85,12 +82,11 @@ function getOneItem() | |||||
{ | { | ||||
var allSel=""; | var allSel=""; | ||||
if (document.form2.arcID.value) return document.form2.arcID.value; | if (document.form2.arcID.value) return document.form2.arcID.value; | ||||
for(i=0;i<document.form2.arcID.length;i++) | |||||
for (i=0;i<document.form2.arcID.length;i++) | |||||
{ | { | ||||
if (document.form2.arcID[i].checked) | |||||
{ | |||||
allSel = document.form2.arcID[i].value; | |||||
break; | |||||
if (document.form2.arcID[i].checked) { | |||||
allSel = document.form2.arcID[i].value; | |||||
break; | |||||
} | } | ||||
} | } | ||||
return allSel; | return allSel; | ||||
@@ -100,10 +96,8 @@ function selAll() | |||||
if (typeof document.form2.arcID.length === "undefined") { | if (typeof document.form2.arcID.length === "undefined") { | ||||
document.form2.arcID.checked = true; | document.form2.arcID.checked = true; | ||||
} | } | ||||
for(i=0;i<document.form2.arcID.length;i++) | |||||
{ | |||||
if (!document.form2.arcID[i].checked) | |||||
{ | |||||
for (i=0;i<document.form2.arcID.length;i++) { | |||||
if (!document.form2.arcID[i].checked) { | |||||
document.form2.arcID[i].checked=true; | document.form2.arcID[i].checked=true; | ||||
} | } | ||||
} | } | ||||
@@ -113,10 +107,8 @@ function noSelAll() | |||||
if (typeof document.form2.arcID.length === "undefined") { | if (typeof document.form2.arcID.length === "undefined") { | ||||
document.form2.arcID.checked = false; | document.form2.arcID.checked = false; | ||||
} | } | ||||
for(i=0;i<document.form2.arcID.length;i++) | |||||
{ | |||||
if (document.form2.arcID[i].checked) | |||||
{ | |||||
for (i=0;i<document.form2.arcID.length;i++) { | |||||
if (document.form2.arcID[i].checked) { | |||||
document.form2.arcID[i].checked=false; | document.form2.arcID[i].checked=false; | ||||
} | } | ||||
} | } |
@@ -1,5 +1,4 @@ | |||||
if (moz == null) | |||||
{ | |||||
if (moz == null) { | |||||
var ie = document.all != null; | var ie = document.all != null; | ||||
var moz = !ie && document.getElementById != null && document.layers == null; | var moz = !ie && document.getElementById != null && document.layers == null; | ||||
} | } | ||||
@@ -13,10 +12,9 @@ function getCheckboxItem() | |||||
{ | { | ||||
var allSel=""; | var allSel=""; | ||||
if (document.form2.mid.value) return document.form2.mid.value; | if (document.form2.mid.value) return document.form2.mid.value; | ||||
for(i=0;i<document.form2.mid.length;i++) | |||||
for (i=0;i<document.form2.mid.length;i++) | |||||
{ | { | ||||
if (document.form2.mid[i].checked) | |||||
{ | |||||
if (document.form2.mid[i].checked) { | |||||
if (allSel=="") | if (allSel=="") | ||||
allSel=document.form2.mid[i].value; | allSel=document.form2.mid[i].value; | ||||
else | else | ||||
@@ -30,10 +28,8 @@ function getOneItem() | |||||
{ | { | ||||
var allSel=""; | var allSel=""; | ||||
if (document.form2.mid.value) return document.form2.mid.value; | if (document.form2.mid.value) return document.form2.mid.value; | ||||
for(i=0;i<document.form2.mid.length;i++) | |||||
{ | |||||
if (document.form2.mid[i].checked) | |||||
{ | |||||
for (i=0;i<document.form2.mid.length;i++) { | |||||
if (document.form2.mid[i].checked) { | |||||
allSel = document.form2.mid[i].value; | allSel = document.form2.mid[i].value; | ||||
break; | break; | ||||
} | } | ||||
@@ -42,20 +38,22 @@ function getOneItem() | |||||
} | } | ||||
function selAll() | function selAll() | ||||
{ | { | ||||
for(i=0;i<document.form2.mid.length;i++) | |||||
{ | |||||
if (!document.form2.mid[i].checked) | |||||
{ | |||||
if (typeof document.form2.mid.length === "undefined") { | |||||
document.form2.mid.checked = true; | |||||
} | |||||
for (i=0;i<document.form2.mid.length;i++) { | |||||
if (!document.form2.mid[i].checked) { | |||||
document.form2.mid[i].checked=true; | document.form2.mid[i].checked=true; | ||||
} | } | ||||
} | } | ||||
} | } | ||||
function noSelAll() | function noSelAll() | ||||
{ | { | ||||
for(i=0;i<document.form2.mid.length;i++) | |||||
{ | |||||
if (document.form2.mid[i].checked) | |||||
{ | |||||
if (typeof document.form2.mid.length === "undefined") { | |||||
document.form2.mid.checked = false; | |||||
} | |||||
for (i=0;i<document.form2.mid.length;i++) { | |||||
if (document.form2.mid[i].checked) { | |||||
document.form2.mid[i].checked=false; | document.form2.mid[i].checked=false; | ||||
} | } | ||||
} | } |
@@ -16,8 +16,8 @@ | |||||
<script src="../static/web/js/moment.min.js"></script> | <script src="../static/web/js/moment.min.js"></script> | ||||
<script src="../static/web/js/daterangepicker.js"></script> | <script src="../static/web/js/daterangepicker.js"></script> | ||||
<script src="../static/web/js/bootstrap.bundle.min.js"></script> | <script src="../static/web/js/bootstrap.bundle.min.js"></script> | ||||
<script src="js/main.js"></script> | |||||
<script src="../static/web/js/cropper.min.js"></script> | <script src="../static/web/js/cropper.min.js"></script> | ||||
<script src="js/main.js"></script> | |||||
<style>table{border-collapse:inherit}</style> | <style>table{border-collapse:inherit}</style> | ||||
<script> | <script> | ||||
function checkSubmit() { | function checkSubmit() { | ||||
@@ -16,8 +16,8 @@ | |||||
<script src="../static/web/js/webajax.js"></script> | <script src="../static/web/js/webajax.js"></script> | ||||
<script src="../static/web/js/moment.min.js"></script> | <script src="../static/web/js/moment.min.js"></script> | ||||
<script src="../static/web/js/daterangepicker.js"></script> | <script src="../static/web/js/daterangepicker.js"></script> | ||||
<script src="js/main.js"></script> | |||||
<script src="../static/web/js/cropper.min.js"></script> | <script src="../static/web/js/cropper.min.js"></script> | ||||
<script src="js/main.js"></script> | |||||
<style>table{border-collapse:inherit}</style> | <style>table{border-collapse:inherit}</style> | ||||
<script> | <script> | ||||
function checkSubmit() | function checkSubmit() | ||||
@@ -202,7 +202,7 @@ | |||||
</td> | </td> | ||||
<td align="center"><button type="button" name="" id="add" class="btn btn-danger btn-sm">删除</button></td> | <td align="center"><button type="button" name="" id="add" class="btn btn-danger btn-sm">删除</button></td> | ||||
</tr> | </tr> | ||||
<?php for($i=2;$i<=10;$i++) {?> | |||||
<?php for ($i=2;$i<=10;$i++) {?> | |||||
<tr class="repeat" align="center"> | <tr class="repeat" align="center"> | ||||
<td class="rank"> | <td class="rank"> | ||||
<input type="hidden" name="posttype<?php echo $i;?>" value="<?php echo $i;?>"> | <input type="hidden" name="posttype<?php echo $i;?>" value="<?php echo $i;?>"> | ||||
@@ -232,7 +232,7 @@ | |||||
</td> | </td> | ||||
<td align="center"><button type="button" name="" id="add" class="btn btn-danger btn-sm">删除</button></td> | <td align="center"><button type="button" name="" id="add" class="btn btn-danger btn-sm">删除</button></td> | ||||
</tr> | </tr> | ||||
<?php for($i=2;$i<=10;$i++) {?> | |||||
<?php for ($i=2;$i<=10;$i++) {?> | |||||
<tr class="repeat" align="center"> | <tr class="repeat" align="center"> | ||||
<td class="rank"> | <td class="rank"> | ||||
<input type="hidden" name="posttype<?php echo $i;?>" value="<?php echo $i;?>"> | <input type="hidden" name="posttype<?php echo $i;?>" value="<?php echo $i;?>"> | ||||
@@ -20,7 +20,7 @@ | |||||
var itemname = theform.itemname.value; | var itemname = theform.itemname.value; | ||||
var dtype = 'text'; | var dtype = 'text'; | ||||
var enums = document.getElementsByName('dtype'); | var enums = document.getElementsByName('dtype'); | ||||
for(i=0;i<enums.length;i++) | |||||
for (i=0;i<enums.length;i++) | |||||
{ | { | ||||
if (enums[i].checked) dtype = enums[i].value; | if (enums[i].checked) dtype = enums[i].value; | ||||
} | } | ||||
@@ -20,7 +20,7 @@ | |||||
var itemname = theform.itemname.value; | var itemname = theform.itemname.value; | ||||
var dtype = 'text'; | var dtype = 'text'; | ||||
var enums = document.getElementsByName('dtype'); | var enums = document.getElementsByName('dtype'); | ||||
for(i=0;i<enums.length;i++) | |||||
for (i=0;i<enums.length;i++) | |||||
{ | { | ||||
if (enums[i].checked) dtype = enums[i].value; | if (enums[i].checked) dtype = enums[i].value; | ||||
} | } | ||||
@@ -16,8 +16,8 @@ | |||||
<script src="../static/web/js/webajax.js"></script> | <script src="../static/web/js/webajax.js"></script> | ||||
<script src="../static/web/js/moment.min.js"></script> | <script src="../static/web/js/moment.min.js"></script> | ||||
<script src="../static/web/js/daterangepicker.js"></script> | <script src="../static/web/js/daterangepicker.js"></script> | ||||
<script src="js/main.js"></script> | |||||
<script src="../static/web/js/cropper.min.js"></script> | <script src="../static/web/js/cropper.min.js"></script> | ||||
<script src="js/main.js"></script> | |||||
<style>table{border-collapse:inherit}</style> | <style>table{border-collapse:inherit}</style> | ||||
<script> | <script> | ||||
function checkSubmit() { | function checkSubmit() { | ||||
@@ -16,8 +16,8 @@ | |||||
<script src="../static/web/js/webajax.js"></script> | <script src="../static/web/js/webajax.js"></script> | ||||
<script src="../static/web/js/moment.min.js"></script> | <script src="../static/web/js/moment.min.js"></script> | ||||
<script src="../static/web/js/daterangepicker.js"></script> | <script src="../static/web/js/daterangepicker.js"></script> | ||||
<script src="js/main.js"></script> | |||||
<script src="../static/web/js/cropper.min.js"></script> | <script src="../static/web/js/cropper.min.js"></script> | ||||
<script src="js/main.js"></script> | |||||
<style>table{border-collapse:inherit}</style> | <style>table{border-collapse:inherit}</style> | ||||
<script> | <script> | ||||
function checkSubmit() { | function checkSubmit() { | ||||
@@ -16,8 +16,8 @@ | |||||
<script src="../static/web/js/moment.min.js"></script> | <script src="../static/web/js/moment.min.js"></script> | ||||
<script src="../static/web/js/daterangepicker.js"></script> | <script src="../static/web/js/daterangepicker.js"></script> | ||||
<script src="../static/web/js/bootstrap.bundle.min.js"></script> | <script src="../static/web/js/bootstrap.bundle.min.js"></script> | ||||
<script src="js/main.js"></script> | |||||
<script src="../static/web/js/cropper.min.js"></script> | <script src="../static/web/js/cropper.min.js"></script> | ||||
<script src="js/main.js"></script> | |||||
<style>table{border-collapse:inherit}</style> | <style>table{border-collapse:inherit}</style> | ||||
<script> | <script> | ||||
function checkSubmit() { | function checkSubmit() { | ||||
@@ -283,7 +283,7 @@ | |||||
<?php | <?php | ||||
$speclisttmp = GetSysTemplets("spec_arclist.htm"); | $speclisttmp = GetSysTemplets("spec_arclist.htm"); | ||||
$nodename = $nodeid = ''; | $nodename = $nodeid = ''; | ||||
for($i=1;$i<=$cfg_specnote;$i++) | |||||
for ($i=1;$i<=$cfg_specnote;$i++) | |||||
{ | { | ||||
if ($i==1) { | if ($i==1) { | ||||
$nodename = '默认节点'; | $nodename = '默认节点'; | ||||
@@ -16,8 +16,8 @@ | |||||
<script src="../static/web/js/moment.min.js"></script> | <script src="../static/web/js/moment.min.js"></script> | ||||
<script src="../static/web/js/daterangepicker.js"></script> | <script src="../static/web/js/daterangepicker.js"></script> | ||||
<script src="../static/web/js/bootstrap.bundle.min.js"></script> | <script src="../static/web/js/bootstrap.bundle.min.js"></script> | ||||
<script src="js/main.js"></script> | |||||
<script src="../static/web/js/cropper.min.js"></script> | <script src="../static/web/js/cropper.min.js"></script> | ||||
<script src="js/main.js"></script> | |||||
<style>table{border-collapse:inherit}</style> | <style>table{border-collapse:inherit}</style> | ||||
<script> | <script> | ||||
function SelectTemplets(fname) { | function SelectTemplets(fname) { | ||||
@@ -363,7 +363,7 @@ | |||||
$i++; | $i++; | ||||
}} | }} | ||||
$dtp->Clear(); | $dtp->Clear(); | ||||
for($i;$i<=$cfg_specnote;$i++) | |||||
for ($i;$i<=$cfg_specnote;$i++) | |||||
{ | { | ||||
?> | ?> | ||||
<tr bgcolor="#e9ecef"> | <tr bgcolor="#e9ecef"> | ||||
@@ -103,7 +103,7 @@ | |||||
<td width="17%">操作</td> | <td width="17%">操作</td> | ||||
</tr> | </tr> | ||||
<?php | <?php | ||||
for($i=0; isset($dedeSysTables[$i]); $i++) | |||||
for ($i=0; isset($dedeSysTables[$i]); $i++) | |||||
{ | { | ||||
$t = $dedeSysTables[$i]; | $t = $dedeSysTables[$i]; | ||||
echo "<tr align='center'>"; | echo "<tr align='center'>"; | ||||
@@ -150,7 +150,7 @@ | |||||
<td>操作</td> | <td>操作</td> | ||||
</tr> | </tr> | ||||
<?php | <?php | ||||
for($i=0; isset($otherTables[$i]); $i++) | |||||
for ($i=0; isset($otherTables[$i]); $i++) | |||||
{ | { | ||||
$t = $otherTables[$i]; | $t = $otherTables[$i]; | ||||
echo "<tr align='center'>"; | echo "<tr align='center'>"; | ||||
@@ -74,7 +74,7 @@ | |||||
<td colspan="4">发现的备份文件:<?php if (count($filelists)==0) echo " 没找到任何备份文件 ";?></td> | <td colspan="4">发现的备份文件:<?php if (count($filelists)==0) echo " 没找到任何备份文件 ";?></td> | ||||
</tr> | </tr> | ||||
<?php | <?php | ||||
for($i=0;$i<count($filelists);$i++) | |||||
for ($i=0;$i<count($filelists);$i++) | |||||
{ | { | ||||
echo "<tr align='center'>"; | echo "<tr align='center'>"; | ||||
$mtd = "<td width='10%'><input name='bakfile' id='bakfile' type='checkbox' value='".$filelists[$i]."' checked='1'></td><td width='40%'>{$filelists[$i]}</td>"; | $mtd = "<td width='10%'><input name='bakfile' id='bakfile' type='checkbox' value='".$filelists[$i]."' checked='1'></td><td width='40%'>{$filelists[$i]}</td>"; | ||||
@@ -29,14 +29,13 @@ if ($tagid !='') | |||||
$dtp2->LoadString($row['innertext']); | $dtp2->LoadString($row['innertext']); | ||||
$GLOBALS['autoindex'] = 0; | $GLOBALS['autoindex'] = 0; | ||||
$ids = array(); | $ids = array(); | ||||
for($i=0; $i<$line; $i++) | |||||
for ($i=0; $i<$line; $i++) | |||||
{ | { | ||||
if ($col>1) $artlist .= "<tr>\r\n"; | if ($col>1) $artlist .= "<tr>\r\n"; | ||||
for($j=0; $j<$col; $j++) | |||||
for ($j=0; $j<$col; $j++) | |||||
{ | { | ||||
if ($col>1) $artlist .= " <td width='$colWidth'>\r\n"; | |||||
if ($row = $dsql->GetArray("al")) | |||||
{ | |||||
if ($col>1) $artlist .= "<td width='$colWidth'>\r\n"; | |||||
if ($row = $dsql->GetArray("al")) { | |||||
$ids[] = $row['id']; | $ids[] = $row['id']; | ||||
//处理一些特殊字段 | //处理一些特殊字段 | ||||
$row['info'] = $row['infos'] = cn_substr($row['description'],$infolen); | $row['info'] = $row['infos'] = cn_substr($row['description'],$infolen); | ||||
@@ -8,8 +8,7 @@ function selNext(oj, v) | |||||
oj.remove(0); | oj.remove(0); | ||||
} | } | ||||
clear(oj); | clear(oj); | ||||
if(selv==0) | |||||
{ | |||||
if (selv==0) { | |||||
aOption = document.createElement('OPTION'); | aOption = document.createElement('OPTION'); | ||||
aOption.text = '具体地区'; | aOption.text = '具体地区'; | ||||
aOption.value = '0'; | aOption.value = '0'; | ||||
@@ -22,9 +21,8 @@ function selNext(oj, v) | |||||
oj.options.add(aOption); | oj.options.add(aOption); | ||||
} | } | ||||
var str = ''; | var str = ''; | ||||
for(i=selv+1; i < maxv; i++) | |||||
{ | |||||
if(!em_nativeplaces[i]) continue; | |||||
for (i=selv+1; i < maxv; i++) { | |||||
if (!em_nativeplaces[i]) continue; | |||||
aOption = document.createElement('OPTION'); | aOption = document.createElement('OPTION'); | ||||
aOption.text = em_nativeplaces[i]; | aOption.text = em_nativeplaces[i]; | ||||
aOption.value = i; | aOption.value = i; | ||||
@@ -36,8 +34,7 @@ function ChangeSon() | |||||
{ | { | ||||
//由于支持3级联动,所以这里需要对自己改变进行重构 | //由于支持3级联动,所以这里需要对自己改变进行重构 | ||||
var emname = this.name.replace('_son', ''); | var emname = this.name.replace('_son', ''); | ||||
if( document.getElementById(emname+'_sec') ) | |||||
{ | |||||
if ( document.getElementById(emname+'_sec') ) { | |||||
var oj = document.getElementById(emname + '_sec'); | var oj = document.getElementById(emname + '_sec'); | ||||
} else { | } else { | ||||
var oj = document.createElement('select'); | var oj = document.createElement('select'); | ||||
@@ -55,8 +52,7 @@ function ChangeSon() | |||||
i = 0; | i = 0; | ||||
while(newobj && newobj.length > 0) oj.remove(0); | while(newobj && newobj.length > 0) oj.remove(0); | ||||
clear(oj); | clear(oj); | ||||
if(selv == 0) | |||||
{ | |||||
if (selv == 0) { | |||||
aOption = document.createElement('OPTION'); | aOption = document.createElement('OPTION'); | ||||
aOption.text = '请选择..'; | aOption.text = '请选择..'; | ||||
aOption.value = '0'; | aOption.value = '0'; | ||||
@@ -70,16 +66,15 @@ function ChangeSon() | |||||
} | } | ||||
var str = ''; | var str = ''; | ||||
var j=0; | var j=0; | ||||
for(i = selv + 0.001; i < maxv; i = FloatAdd(i, 0.001)) | |||||
{ | |||||
if(!selarr[i]) continue; | |||||
for (i = selv + 0.001; i < maxv; i = FloatAdd(i, 0.001)) { | |||||
if (!selarr[i]) continue; | |||||
aOption = document.createElement('OPTION'); | aOption = document.createElement('OPTION'); | ||||
aOption.text = selarr[i]; | aOption.text = selarr[i]; | ||||
aOption.value = i; | aOption.value = i; | ||||
oj.options.add(aOption); | oj.options.add(aOption); | ||||
j++; | j++; | ||||
} | } | ||||
if(j > 0) document.getElementById('span_'+emname+'_sec').appendChild(oj); | |||||
if (j > 0) document.getElementById('span_'+emname+'_sec').appendChild(oj); | |||||
else document.getElementById('span_'+emname+'_sec').innerHTML = ""; | else document.getElementById('span_'+emname+'_sec').innerHTML = ""; | ||||
} | } | ||||
//改变第三级的事件 | //改变第三级的事件 | ||||
@@ -87,7 +82,7 @@ function ChangeSec() | |||||
{ | { | ||||
var emname = this.name.replace('_sec', ''); | var emname = this.name.replace('_sec', ''); | ||||
var topSelObj = document.getElementById(emname+'_top'); | var topSelObj = document.getElementById(emname+'_top'); | ||||
if(this.options[this.selectedIndex].value==0) { | |||||
if (this.options[this.selectedIndex].value==0) { | |||||
document.getElementById('hidden_'+emname).value = topSelObj.options[topSelObj.selectedIndex].value; | document.getElementById('hidden_'+emname).value = topSelObj.options[topSelObj.selectedIndex].value; | ||||
} else { | } else { | ||||
document.getElementById('hidden_'+emname).value = this.options[this.selectedIndex].value; | document.getElementById('hidden_'+emname).value = this.options[this.selectedIndex].value; | ||||
@@ -97,8 +92,7 @@ function ChangeSec() | |||||
function selNextSon() | function selNextSon() | ||||
{ | { | ||||
var emname = this.name.replace('_top', ''); | var emname = this.name.replace('_top', ''); | ||||
if( document.getElementById(emname+'_son') ) | |||||
{ | |||||
if ( document.getElementById(emname+'_son') ) { | |||||
var oj = document.getElementById(emname + '_son'); | var oj = document.getElementById(emname + '_son'); | ||||
} else { | } else { | ||||
var oj = document.createElement('select'); | var oj = document.createElement('select'); | ||||
@@ -115,8 +109,7 @@ function selNextSon() | |||||
var maxv = parseInt(v) + 500; | var maxv = parseInt(v) + 500; | ||||
while(newobj && newobj.length > 0) oj.remove(0); | while(newobj && newobj.length > 0) oj.remove(0); | ||||
clear(oj); | clear(oj); | ||||
if(selv==0) | |||||
{ | |||||
if (selv==0) { | |||||
aOption = document.createElement('OPTION'); | aOption = document.createElement('OPTION'); | ||||
aOption.text = '请选择..'; | aOption.text = '请选择..'; | ||||
aOption.value = '0'; | aOption.value = '0'; | ||||
@@ -129,9 +122,8 @@ function selNextSon() | |||||
oj.options.add(aOption); | oj.options.add(aOption); | ||||
} | } | ||||
var str = ''; | var str = ''; | ||||
for(i=selv+1; i < maxv; i++) | |||||
{ | |||||
if(!selarr[i]) continue; | |||||
for (i=selv+1; i < maxv; i++) { | |||||
if (!selarr[i]) continue; | |||||
aOption = document.createElement('OPTION'); | aOption = document.createElement('OPTION'); | ||||
aOption.text = selarr[i]; | aOption.text = selarr[i]; | ||||
aOption.value = i; | aOption.value = i; | ||||
@@ -157,12 +149,11 @@ function MakeTopSelect(emname, selvalue) | |||||
aOption.text = '请选择..'; | aOption.text = '请选择..'; | ||||
aOption.value = 0; | aOption.value = 0; | ||||
selObj.options.add(aOption); | selObj.options.add(aOption); | ||||
if(selvalue % 500 == 0 ) | |||||
{ | |||||
if (selvalue % 500 == 0 ) { | |||||
topvalue = selvalue; | topvalue = selvalue; | ||||
} | } | ||||
//如果是小数,则依次取出顶级数值,二级数值以及三级数值 | //如果是小数,则依次取出顶级数值,二级数值以及三级数值 | ||||
else if(!!(selvalue % 1)) | |||||
else if (!!(selvalue % 1)) | |||||
{ | { | ||||
secvalue = selvalue; | secvalue = selvalue; | ||||
sonvalue = Math.floor(selvalue); | sonvalue = Math.floor(selvalue); | ||||
@@ -172,11 +163,10 @@ function MakeTopSelect(emname, selvalue) | |||||
sonvalue = selvalue; | sonvalue = selvalue; | ||||
topvalue = selvalue - (selvalue % 500); | topvalue = selvalue - (selvalue % 500); | ||||
} | } | ||||
for(i = 500; i <= selarr.length; i += 500) | |||||
{ | |||||
if(!selarr[i]) continue; | |||||
for (i = 500; i <= selarr.length; i += 500) { | |||||
if (!selarr[i]) continue; | |||||
aOption = document.createElement('OPTION'); | aOption = document.createElement('OPTION'); | ||||
if(i == topvalue) { | |||||
if (i == topvalue) { | |||||
aOption = document.createElement('OPTION'); | aOption = document.createElement('OPTION'); | ||||
aOption.text = selarr[i]; | aOption.text = selarr[i]; | ||||
aOption.value = i; | aOption.value = i; | ||||
@@ -201,15 +191,14 @@ function MakeTopSelect(emname, selvalue) | |||||
aOption.value = 0; | aOption.value = 0; | ||||
selObj.options.add(aOption); | selObj.options.add(aOption); | ||||
//当大类有值输出子类 | //当大类有值输出子类 | ||||
if(topvalue > 0) | |||||
if (topvalue > 0) | |||||
{ | { | ||||
var selv = topvalue; | var selv = topvalue; | ||||
var maxv = parseInt(topvalue) + 500; | var maxv = parseInt(topvalue) + 500; | ||||
for(i = selv + 1; i < maxv; i++) | |||||
{ | |||||
if(!selarr[i]) continue; | |||||
for (i = selv + 1; i < maxv; i++) { | |||||
if (!selarr[i]) continue; | |||||
aOption = document.createElement('OPTION'); | aOption = document.createElement('OPTION'); | ||||
if(i == sonvalue) { | |||||
if (i == sonvalue) { | |||||
aOption = document.createElement('OPTION'); | aOption = document.createElement('OPTION'); | ||||
aOption.text = selarr[i]; | aOption.text = selarr[i]; | ||||
aOption.value = i; | aOption.value = i; | ||||
@@ -225,8 +214,7 @@ function MakeTopSelect(emname, selvalue) | |||||
} | } | ||||
document.getElementById('span_'+emname+'_son').appendChild(selObj); | document.getElementById('span_'+emname+'_son').appendChild(selObj); | ||||
//若存在第三级则创建 | //若存在第三级则创建 | ||||
if(secvalue > 0) | |||||
{ | |||||
if (secvalue > 0) { | |||||
selObj = document.createElement("select"); | selObj = document.createElement("select"); | ||||
selObj.name = emname + '_sec'; | selObj.name = emname + '_sec'; | ||||
selObj.id = emname + '_sec'; | selObj.id = emname + '_sec'; | ||||
@@ -239,11 +227,10 @@ function MakeTopSelect(emname, selvalue) | |||||
var selv = sonvalue; | var selv = sonvalue; | ||||
var maxv = parseInt(sonvalue) + 0.5; | var maxv = parseInt(sonvalue) + 0.5; | ||||
i = 0; | i = 0; | ||||
for(i = selv + 0.001; i < maxv; i = FloatAdd(i, 0.001)) | |||||
{ | |||||
if(!selarr[i]) continue; | |||||
for (i = selv + 0.001; i < maxv; i = FloatAdd(i, 0.001)) { | |||||
if (!selarr[i]) continue; | |||||
aOption = document.createElement('OPTION'); | aOption = document.createElement('OPTION'); | ||||
if(i == secvalue) { | |||||
if (i == secvalue) { | |||||
aOption = document.createElement('OPTION'); | aOption = document.createElement('OPTION'); | ||||
aOption.text = selarr[i]; | aOption.text = selarr[i]; | ||||
aOption.value = i; | aOption.value = i; | ||||
@@ -272,7 +259,7 @@ function FloatAdd(arg1, arg2) | |||||
function clear(o) | function clear(o) | ||||
{ | { | ||||
l=o.length; | l=o.length; | ||||
for (i = 0; i< l; i++){ | |||||
for (i = 0; i< l; i++) { | |||||
o.options[1]=null; | o.options[1]=null; | ||||
} | } | ||||
} | } |
@@ -1,15 +1,15 @@ | |||||
function checkSubmit() | function checkSubmit() | ||||
{ | { | ||||
if(document.form1.title.value=='') { | |||||
if (document.form1.title.value=='') { | |||||
alert("图片标题不能为空"); | alert("图片标题不能为空"); | ||||
document.form1.title.focus(); | document.form1.title.focus(); | ||||
return false; | return false; | ||||
} | } | ||||
if(document.form1.typeid.value==0) { | |||||
if (document.form1.typeid.value==0) { | |||||
alert("所属栏目必须选择"); | alert("所属栏目必须选择"); | ||||
return false; | return false; | ||||
} | } | ||||
if(document.form1.typeid.options[document.form1.typeid.selectedIndex].className!='option3') | |||||
if (document.form1.typeid.options[document.form1.typeid.selectedIndex].className!='option3') | |||||
{ | { | ||||
alert("所属栏目必须选择白色背景的项目"); | alert("所属栏目必须选择白色背景的项目"); | ||||
return false; | return false; | ||||
@@ -21,7 +21,7 @@ function checkSubmit() | |||||
function CheckSelTable(nnum){ | function CheckSelTable(nnum){ | ||||
var cbox = document.getElementById('isokcheck'+nnum); | var cbox = document.getElementById('isokcheck'+nnum); | ||||
var seltb = document.getElementById('seltb'+nnum); | var seltb = document.getElementById('seltb'+nnum); | ||||
if(!cbox.checked) seltb.style.display = 'none'; | |||||
if (!cbox.checked) seltb.style.display = 'none'; | |||||
else seltb.style.display = 'block'; | else seltb.style.display = 'block'; | ||||
} | } | ||||
var startNum = 1; | var startNum = 1; | ||||
@@ -33,12 +33,12 @@ function MakeUpload(mnum) | |||||
var fhtml = ""; | var fhtml = ""; | ||||
var dsel = " checked='checked' "; | var dsel = " checked='checked' "; | ||||
var dplay = "display:none"; | var dplay = "display:none"; | ||||
if(mnum==0) endNum = startNum + Number(pnumObj.value); | |||||
if (mnum==0) endNum = startNum + Number(pnumObj.value); | |||||
else endNum = mnum; | else endNum = mnum; | ||||
if(endNum>120) endNum = 120; | |||||
for(startNum;startNum < endNum;startNum++) | |||||
if (endNum>120) endNum = 120; | |||||
for (startNum;startNum < endNum;startNum++) | |||||
{ | { | ||||
if(startNum==1){ | |||||
if (startNum==1){ | |||||
dsel = " checked='checked' "; | dsel = " checked='checked' "; | ||||
dplay = "block"; | dplay = "block"; | ||||
} else { | } else { | ||||
@@ -74,12 +74,12 @@ function LoadTestDiv() | |||||
var newobj = document.getElementById('_myhtml'); | var newobj = document.getElementById('_myhtml'); | ||||
document.getElementById('imagebody').value = document.getElementById('copyhtml').innerHTML; | document.getElementById('imagebody').value = document.getElementById('copyhtml').innerHTML; | ||||
var dfstr = '粘贴到这里...'; | var dfstr = '粘贴到这里...'; | ||||
if(document.getElementById('imagebody').value.length <= dfstr.length) | |||||
if (document.getElementById('imagebody').value.length <= dfstr.length) | |||||
{ | { | ||||
alert('您还没有粘贴任何东西在编辑框'); | alert('您还没有粘贴任何东西在编辑框'); | ||||
return; | return; | ||||
} | } | ||||
if(!newobj){ | |||||
if (!newobj){ | |||||
newobj = document.createElement("DIV"); | newobj = document.createElement("DIV"); | ||||
newobj.id = '_myhtml'; | newobj.id = '_myhtml'; | ||||
newobj.style.position='absolute'; | newobj.style.position='absolute'; | ||||
@@ -105,21 +105,21 @@ function LoadTestDiv() | |||||
} | } | ||||
function checkMuList(psid,cmid) | function checkMuList(psid,cmid) | ||||
{ | { | ||||
if(document.getElementById('pagestyle3').checked) | |||||
if (document.getElementById('pagestyle3').checked) | |||||
{ | { | ||||
document.getElementById('spagelist').style.display = 'none'; | document.getElementById('spagelist').style.display = 'none'; | ||||
} | } | ||||
else if(document.getElementById('pagestyle1').checked) | |||||
else if (document.getElementById('pagestyle1').checked) | |||||
{ | { | ||||
document.getElementById('spagelist').style.display = 'block'; | document.getElementById('spagelist').style.display = 'block'; | ||||
} else { | } else { | ||||
document.getElementById('spagelist').style.display = 'none'; | document.getElementById('spagelist').style.display = 'none'; | ||||
} | } | ||||
} | } | ||||
//图片,显示与隐藏zip文件选项 | |||||
//图片显示与隐藏zip文件选项 | |||||
function ShowZipField(formitem,zipid,upid) | function ShowZipField(formitem,zipid,upid) | ||||
{ | { | ||||
if(formitem.checked){ | |||||
if (formitem.checked){ | |||||
document.getElementById(zipid).style.display = 'block'; | document.getElementById(zipid).style.display = 'block'; | ||||
document.getElementById(upid).style.display = 'none'; | document.getElementById(upid).style.display = 'none'; | ||||
document.getElementById('formhtml').checked = false; | document.getElementById('formhtml').checked = false; | ||||
@@ -128,14 +128,14 @@ function ShowZipField(formitem,zipid,upid) | |||||
document.getElementById(zipid).style.display = 'none'; | document.getElementById(zipid).style.display = 'none'; | ||||
} | } | ||||
} | } | ||||
//图片,显示与隐藏Html编辑框 | |||||
//图片显示与隐藏Html编辑框 | |||||
function ShowHtmlField(formitem,htmlid,upid) | function ShowHtmlField(formitem,htmlid,upid) | ||||
{ | { | ||||
if($Nav()!="IE"){ | |||||
if ($Nav()!="IE"){ | |||||
alert("该方法不适用于非IE浏览器"); | alert("该方法不适用于非IE浏览器"); | ||||
return ; | return ; | ||||
} | } | ||||
if(formitem.checked){ | |||||
if (formitem.checked){ | |||||
document.getElementById(htmlid).style.display = 'block'; | document.getElementById(htmlid).style.display = 'block'; | ||||
} else { | } else { | ||||
document.getElementById(htmlid).style.display = 'none'; | document.getElementById(htmlid).style.display = 'none'; | ||||
@@ -5,15 +5,12 @@ function $DE(id) { | |||||
//读写cookie函数 | //读写cookie函数 | ||||
function GetCookie(c_name) | function GetCookie(c_name) | ||||
{ | { | ||||
if (document.cookie.length > 0) | |||||
{ | |||||
if (document.cookie.length > 0) { | |||||
c_start = document.cookie.indexOf(c_name + "=") | c_start = document.cookie.indexOf(c_name + "=") | ||||
if (c_start != -1) | |||||
{ | |||||
if (c_start != -1) { | |||||
c_start = c_start + c_name.length + 1; | c_start = c_start + c_name.length + 1; | ||||
c_end = document.cookie.indexOf(";",c_start); | c_end = document.cookie.indexOf(";",c_start); | ||||
if (c_end == -1) | |||||
{ | |||||
if (c_end == -1) { | |||||
c_end = document.cookie.length; | c_end = document.cookie.length; | ||||
} | } | ||||
return unescape(document.cookie.substring(c_start,c_end)); | return unescape(document.cookie.substring(c_start,c_end)); | ||||
@@ -715,7 +715,7 @@ class SgListView | |||||
$optionlen = strlen($totalpage); | $optionlen = strlen($totalpage); | ||||
$optionlen = $optionlen*10+18; | $optionlen = $optionlen*10+18; | ||||
$optionlist = "<li><select name='sldd' style='width:{$optionlen}px' onchange='location.href=this.options[this.selectedIndex].value;'>\r\n"; | $optionlist = "<li><select name='sldd' style='width:{$optionlen}px' onchange='location.href=this.options[this.selectedIndex].value;'>\r\n"; | ||||
for($mjj=1;$mjj<=$totalpage;$mjj++) | |||||
for ($mjj=1;$mjj<=$totalpage;$mjj++) | |||||
{ | { | ||||
if ($mjj==$this->PageNo) | if ($mjj==$this->PageNo) | ||||
{ | { | ||||
@@ -5,16 +5,14 @@ function SpHtml2Text($str) | |||||
$str = preg_replace("/<sty(.*)\\/style>|<scr(.*)\\/script>|<!--(.*)-->/isU","",$str); | $str = preg_replace("/<sty(.*)\\/style>|<scr(.*)\\/script>|<!--(.*)-->/isU","",$str); | ||||
$alltext = ""; | $alltext = ""; | ||||
$start = 1; | $start = 1; | ||||
for($i=0;$i<strlen($str);$i++) | |||||
for ($i=0;$i<strlen($str);$i++) | |||||
{ | { | ||||
if ($start==0 && $str[$i]==">") | |||||
{ | |||||
if ($start==0 && $str[$i]==">") { | |||||
$start = 1; | $start = 1; | ||||
} | } | ||||
else if ($start==1) | else if ($start==1) | ||||
{ | { | ||||
if ($str[$i]=="<") | |||||
{ | |||||
if ($str[$i]=="<") { | |||||
$start = 0; | $start = 0; | ||||
$alltext .= " "; | $alltext .= " "; | ||||
} | } | ||||
@@ -31,7 +31,7 @@ if (!defined('DEDEINC')) exit('dedebiz'); | |||||
$len = count($frame); | $len = count($frame); | ||||
foreach ($frame as &$frameLine) { | foreach ($frame as &$frameLine) { | ||||
for($i=0; $i<$len; $i++) { | |||||
for ($i=0; $i<$len; $i++) { | |||||
$frameLine[$i] = (ord($frameLine[$i])&1)?'1':'0'; | $frameLine[$i] = (ord($frameLine[$i])&1)?'1':'0'; | ||||
} | } | ||||
} | } | ||||
@@ -116,8 +116,8 @@ if (!defined('DEDEINC')) exit('dedebiz'); | |||||
public static function dumpMask($frame) | public static function dumpMask($frame) | ||||
{ | { | ||||
$width = count($frame); | $width = count($frame); | ||||
for($y=0;$y<$width;$y++) { | |||||
for($x=0;$x<$width;$x++) { | |||||
for ($y=0;$y<$width;$y++) { | |||||
for ($x=0;$x<$width;$x++) { | |||||
echo ord($frame[$y][$x]).','; | echo ord($frame[$y][$x]).','; | ||||
} | } | ||||
} | } | ||||
@@ -31,7 +31,7 @@ | |||||
$dsql->SetQuery("SELECT * FROM `#@__flink` WHERE ischeck>0 ORDER BY sortrank ASC"); | $dsql->SetQuery("SELECT * FROM `#@__flink` WHERE ischeck>0 ORDER BY sortrank ASC"); | ||||
$dsql->Execute(); | $dsql->Execute(); | ||||
$revalue = ""; | $revalue = ""; | ||||
for($i=1;$i<=$row;$i++) | |||||
for ($i=1;$i<=$row;$i++) | |||||
{ | { | ||||
if ($dbrow=$dsql->GetObject()) | if ($dbrow=$dsql->GetObject()) | ||||
{ | { | ||||