소스 검색

细节调整

pull/12/head
xushubieli 2 년 전
부모
커밋
afd8524e69
6개의 변경된 파일125개의 추가작업 그리고 146개의 파일을 삭제
  1. +96
    -109
      src/admin/dialog/select_images.php
  2. +12
    -13
      src/admin/dialog/select_media.php
  3. +12
    -18
      src/admin/dialog/select_templets.php
  4. +1
    -1
      src/admin/templets/index_menu2.htm
  5. +3
    -4
      src/admin/templets/login.htm
  6. +1
    -1
      src/install/templates/step-1.html

+ 96
- 109
src/admin/dialog/select_images.php 파일 보기

@@ -125,117 +125,104 @@ table{background:#fff}
</script>
<table width="100%" border="0" cellpadding="0" cellspacing="1" align="center" class="table table-borderless">
<tr>
<td colspan="4">
<table width="100%" border="0" cellspacing="0" cellpadding="2">
<tr>
<td width="10%" class="linerow">预览</td>
<td width="40%" class="linerow">选择图片</td>
<td width="20%" class="linerow">文件大小</td>
<td width="30%" class="linerow">修改时间</td>
</tr>
<tr>
<td class="linerow" colspan="4">点击图片预览,点击图片名选择图片,显示图片后点击该图片关闭预览。</td>
</tr>
<?php
$dh = dir($inpath);
$ty1 = "";
$ty2 = "";
while ($file = $dh->read()) {
//计算文件大小和创建时间
if ($file != "." && $file != ".." && !is_dir("$inpath/$file")) {
$filesize = filesize("$inpath/$file");
$filesize = $filesize / 1024;
if ($filesize != "")
if ($filesize < 0.1) {
@list($ty1, $ty2) = split("\.", $filesize);
$filesize = $ty1.".".substr($ty2, 0, 2);
} else {
@list($ty1, $ty2) = split("\.", $filesize);
$filesize = $ty1.".".substr($ty2, 0, 1);
}
$filetime = filemtime("$inpath/$file");
$filetime = MyDate("Y-m-d H:i", $filetime);
}
if ($file == ".") continue;
else if ($file == "..") {
if ($activepath == "") continue;
$tmp = preg_replace("#[\/][^\/]*$#i", "", $activepath);
$line = "<tr>
<td class='linerow' colspan='2'>
<a href='select_images.php?imgstick=$imgstick&v=$v&f=$f&activepath=".urlencode($tmp).$addparm."'><img src='img/dir2.gif'>上级目录</a></td>
<td colspan='2' class='linerow'>当前目录:$activepath</td>
</tr>";
echo $line;
} else if (is_dir("$inpath/$file")) {
if (preg_match("#^_(.*)$#i", $file)) continue;
if (preg_match("#^\.(.*)$#i", $file)) continue;
$line = "<tr>
<td class='linerow' colspan='2'>
<a href='select_images.php?imgstick=$imgstick&v=$v&f=$f&activepath=".urlencode("$activepath/$file").$addparm."'><img src='img/dir.gif'>$file</a></td>
<td class='linerow'></td>
<td class='linerow'></td>
</tr>";
echo "$line";
} else if (preg_match("#\.(".$cfg_imgtype.")#i", $file)) {
$reurl = "$activeurl/$file";
$reurl = preg_replace("#^\.\.#", "", $reurl);
$reurl = $reurl;
if ($file == $comeback) $lstyle = " style='color:red' ";
else $lstyle = "";
$line = "<tr>
<td class='linerow'><a href=\"#\" onClick=\"ChangeImage('$reurl');\"><img src='img/picviewnone.gif'></a>
</td>
<td class='linerow'><a href=# onclick=\"ReturnImg('$reurl');\" $lstyle><img src='img/gif.gif'>$file</a></td>
<td class='linerow'>$filesize KB</td>
<td class='linerow'>$filetime</td>
</tr>";
echo "$line";
} else if (preg_match("#\.(jpg)#i", $file)) {
$reurl = "$activeurl/$file";
$reurl = preg_replace("#^\.\.#", "", $reurl);
$reurl = $reurl;
if ($file == $comeback) $lstyle = " style='color:red' ";
else $lstyle = "";
$line = "<tr>
<td class='linerow'><a href=\"#\" onClick=\"ChangeImage('$reurl');\"><img src='img/picviewnone.gif'></a></td>
<td class='linerow'><a href=# onclick=\"ReturnImg('$reurl');\" $lstyle><img src='img/jpg.gif'>$file</a></td>
<td class='linerow'>$filesize KB</td>
<td class='linerow'>$filetime</td>
</tr>";
echo "$line";
}
}//End Loop
$dh->close();
?>
<tr>
<td colspan="4">
<table width="100%">
<form action="select_images_post.php" method="POST" enctype="multipart/form-data" name="myform">
<?php $noeditor = !empty($noeditor) ? "<input type='hidden' name='noeditor' value='yes'>" : '';
echo $noeditor; ?>
<input type="hidden" name="activepath" value="<?php echo $activepath ?>">
<input type="hidden" name="f" value="<?php echo $f ?>">
<input type="hidden" name="v" value="<?php echo $v ?>">
<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">
<tr>
<td>
上传:<input type="file" name="imgfile" style="width:160px;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">
高:<input type="text" name="iheight" value="<?php echo $cfg_ddimg_height ?>" style="width:46px">
<button type="submit" name="sb1" class="btn btn-success btn-sm">确定</button>
</td>
</tr>
</form>
</table>
</td>
</tr>
</table>
<td colspan="4" height="30">
<form action="select_images_post.php" method="POST" enctype="multipart/form-data" name="myform">
<?php $noeditor = !empty($noeditor) ? "<input type='hidden' name='noeditor' value='yes'>" : ''; echo $noeditor; ?>
<input type="hidden" name="activepath" value="<?php echo $activepath ?>">
<input type="hidden" name="f" value="<?php echo $f ?>">
<input type="hidden" name="v" value="<?php echo $v ?>">
<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">
<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">
高:<input type="text" name="iheight" value="<?php echo $cfg_ddimg_height ?>" style="width:46px">
<button type="submit" name="sb1" class="btn btn-success btn-sm">确定</button>
</form>
</td>
</tr>
<tr>
<td width="10%" class="linerow">预览</td>
<td width="40%" class="linerow">选择图片</td>
<td width="20%" class="linerow">文件大小</td>
<td width="30%" class="linerow">修改时间</td>
</tr>
<tr>
<td class="linerow" colspan="4">点击图片预览,点击图片名选择图片,显示图片后点击该图片关闭预览。</td>
</tr>
<?php
$dh = dir($inpath);
$ty1 = "";
$ty2 = "";
while ($file = $dh->read()) {
//计算文件大小和创建时间
if ($file != "." && $file != ".." && !is_dir("$inpath/$file")) {
$filesize = filesize("$inpath/$file");
$filesize = $filesize / 1024;
if ($filesize != "")
if ($filesize < 0.1) {
@list($ty1, $ty2) = split("\.", $filesize);
$filesize = $ty1.".".substr($ty2, 0, 2);
} else {
@list($ty1, $ty2) = split("\.", $filesize);
$filesize = $ty1.".".substr($ty2, 0, 1);
}
$filetime = filemtime("$inpath/$file");
$filetime = MyDate("Y-m-d H:i", $filetime);
}
if ($file == ".") continue;
else if ($file == "..") {
if ($activepath == "") continue;
$tmp = preg_replace("#[\/][^\/]*$#i", "", $activepath);
$line = "<tr>
<td class='linerow' colspan='2'>
<a href='select_images.php?imgstick=$imgstick&v=$v&f=$f&activepath=".urlencode($tmp).$addparm."'><img src='img/dir2.gif'>上级目录</a></td>
<td colspan='2' class='linerow'>当前目录:$activepath</td>
</tr>";
echo $line;
} else if (is_dir("$inpath/$file")) {
if (preg_match("#^_(.*)$#i", $file)) continue;
if (preg_match("#^\.(.*)$#i", $file)) continue;
$line = "<tr>
<td class='linerow' colspan='2'>
<a href='select_images.php?imgstick=$imgstick&v=$v&f=$f&activepath=".urlencode("$activepath/$file").$addparm."'><img src='img/dir.gif'>$file</a></td>
<td class='linerow'></td>
<td class='linerow'></td>
</tr>";
echo "$line";
} else if (preg_match("#\.(".$cfg_imgtype.")#i", $file)) {
$reurl = "$activeurl/$file";
$reurl = preg_replace("#^\.\.#", "", $reurl);
$reurl = $reurl;
if ($file == $comeback) $lstyle = " style='color:red' ";
else $lstyle = "";
$line = "<tr>
<td class='linerow'><a href=\"#\" onClick=\"ChangeImage('$reurl');\"><img src='img/picviewnone.gif'></a></td>
<td class='linerow'><a href=# onclick=\"ReturnImg('$reurl');\" $lstyle><img src='img/gif.gif'>$file</a></td>
<td class='linerow'>$filesize KB</td>
<td class='linerow'>$filetime</td>
</tr>";
echo "$line";
} else if (preg_match("#\.(jpg)#i", $file)) {
$reurl = "$activeurl/$file";
$reurl = preg_replace("#^\.\.#", "", $reurl);
$reurl = $reurl;
if ($file == $comeback) $lstyle = " style='color:red' ";
else $lstyle = "";
$line = "<tr>
<td class='linerow'><a href=\"#\" onClick=\"ChangeImage('$reurl');\"><img src='img/picviewnone.gif'></a></td>
<td class='linerow'><a href=# onclick=\"ReturnImg('$reurl');\" $lstyle><img src='img/jpg.gif'>$file</a></td>
<td class='linerow'>$filesize KB</td>
<td class='linerow'>$filetime</td>
</tr>";
echo "$line";
}
}//End Loop
$dh->close();
?>
</tr>
</table>
</body>
</html>

+ 12
- 13
src/admin/dialog/select_media.php 파일 보기

@@ -74,6 +74,18 @@ table{background:#fff}
}
</script>
<table width="100%" border="0" align="center" cellspacing="0" cellpadding="2" class="table table-borderless">
<tr>
<td colspan="3" height="30">
<form action="select_media_post.php" method="POST" enctype="multipart/form-data" name="myform">
<input type="hidden" name="activepath" value="<?php echo $activepath ?>">
<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">
<button type="submit" name="sb1" class="btn btn-success btn-sm">确定</button>
</form>
</td>
</tr>
<tr>
<td width="55%" align="center" class="linerow">点击名称选择文件</td>
<td width="15%" align="center" class="linerow">文件大小</td>
@@ -170,19 +182,6 @@ table{background:#fff}
}//End Loop
$dh->close();
?>
<tr>
<td colspan="3">
<form action="select_media_post.php" method="POST" enctype="multipart/form-data" name="myform">
<input type="hidden" name="activepath" value="<?php echo $activepath ?>">
<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">
<button type="submit" name="sb1" class="btn btn-success btn-sm">确定</button>
</form>
</table>
</td>
</tr>
</table>
</body>
</html>

+ 12
- 18
src/admin/dialog/select_templets.php 파일 보기

@@ -59,6 +59,18 @@ table{background:#fff}
}
</script>
<table width="100%" border="0" cellpadding="0" cellspacing="1" align="center" class="table table-borderless">
<tr>
<td colspan="3" height="30">
<form action="select_templets_post.php" method="POST" enctype="multipart/form-data" name="myform">
<input type="hidden" name="activepath" value="<?php echo $activepath ?>">
<input type="hidden" name="f" value="<?php echo $f ?>">
<input type="hidden" name="job" value="upload">
上传:<input type="file" name="uploadfile" style="width:260px;border:none">
改名:<input type="text" name="filename" style="width:160px">
<button type="submit" name="sb1" class="btn btn-success btn-sm">确定</button>
</form>
</td>
</tr>
<tr>
<td width="50%" class="linerow">选择文件</td>
<td width="20%" class="linerow">文件大小</td>
@@ -178,24 +190,6 @@ table{background:#fff}
}//End Loop
$dh->close();
?>
<tr>
<td colspan="3">
<table width="100%">
<form action="select_templets_post.php" method="POST" enctype="multipart/form-data" name="myform">
<input type="hidden" name="activepath" value="<?php echo $activepath ?>">
<input type="hidden" name="f" value="<?php echo $f ?>">
<input type="hidden" name="job" value="upload">
<tr>
<td>
上传:<input type="file" name="uploadfile" style="width:260px;border:none">
改名:<input type="text" name="filename" style="width:160px">
<button type="submit" name="sb1" class="btn btn-success btn-sm">确定</button>
</td>
</tr>
</form>
</table>
</td>
</tr>
</table>
</body>
</html>

+ 1
- 1
src/admin/templets/index_menu2.htm 파일 보기

@@ -11,7 +11,7 @@ echo "<script>var curopenItem = '$openitem';</script>";
?>
<script src="js/leftmenu.js"></script>
<style>
body{margin:0;background:#f8f8f8;padding-left:6px;overflow:scroll;overflow-x:hidden}
body{margin:0;background:#f6f6f6;padding-left:6px;overflow:scroll;overflow-x:hidden}
img{margin-right:0;border-radius:0}
div{margin:0;padding:0}
dl.bitem{margin:0 0 2px 10px;width:140px;background:url(images/menunewbg.gif)repeat-x;clear:both}


+ 3
- 4
src/admin/templets/login.htm 파일 보기

@@ -9,14 +9,15 @@
<link rel="stylesheet" href="../static/css/dede.css">
<title><?php echo $cfg_webname; ?>后台登录</title>
<style>
body{font:14px Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif;color:#424b51;background:#f8f8f8}
body{font:14px Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif;color:#424b51;background:#f2f2f2}
img{max-width:100%}
input{font-size:14px!important}
header{background:#fff}
header .logo{width:300px;padding:1rem 0}
.goindex{line-height:68px}
.fa{font-size:16px}
.login-from{max-width:580px;width:100%}
.login-area{background:#fff;padding:2rem;border-radius:.25rem}
.login-area{background:#fff;padding:1.25rem;border-radius:.25rem}
.login-area .btnLogin{width:100%}
.login-power{padding-top:1rem}
.login-power a,.goindex a{color:#008e38}
@@ -70,7 +71,5 @@ header .logo{width:300px;padding:1rem 0}
</form>
</div>
</main>
<script src="../static/js/jquery.min.js"></script>
<script src="../static/js/bootstrap.bundle.js"></script>
</body>
</html>

+ 1
- 1
src/install/templates/step-1.html 파일 보기

@@ -9,7 +9,7 @@
<script src="../static/js/popper.min.js"></script>
<script src="../static/js/bootstrap.bundle.js"></script>
<script src="../static/js/dede.js"></script>
<style>body,input{font-size:14px!important}@media (min-width:1200px){.container{max-width:960px}}</style>
<style>body{font:14px Helvetica Neue,Helvetica,PingFang SC,Tahoma,Arial,sans-serif;color:#424b51;background:#f2f2f2}input{font-size:14px!important}@media (min-width:1200px){.container{max-width:960px}}</style>
</head>
<body>
<div class="d-flex flex-column flex-md-row align-items-center mb-3 p-3 px-md-4 bg-white border-bottom shadow-sm">


불러오는 중...
취소
저장