?? tempftp.php
字號:
<?php
include("../config.inc.php");
include("../includes/SysGlobal.php");
include("language/".$aLan."_".$charset.".php");
include("../includes/version.php");
include("../includes/pro.php");
include("func/adm.inc.php");
include("func/common.inc.php");
include("func/link.inc.php");
include("func/temp.inc.php");
include("func/db.inc.php");
include("func/nocatch.php");
NeedAuth(14);
ChkLic();
?>
<html>
<head >
<meta http-equiv="Content-Type" content="text/html; charset=<?php echo $charset; ?>">
<link id="style_sheet" href="css/commonstyle.css" type="text/css" rel="stylesheet">
<title><?php echo $strAdminTitle; ?></title>
</head>
<body class="NavigatorBar">
<table width="100%" border="0" cellspacing="1" cellpadding="0" align="center" background="images/mu8.gif" height="30" >
<tr>
<td > <img src="images/bar.gif" > <?php echo $strTempFileGl; ?></td>
<td width="70" align="center" > </td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0" background="images/mu1.jpg" height="5">
<tr>
<td></td>
</tr>
</table>
<?php
$step=$_REQUEST["step"];
$fold=$_REQUEST["fold"];
if($fold=="" || strstr($fold,"/") || strstr($fold,":")){
echo "No rights for this fold";
exit;
}
$openfold="../templates/".$fold;
$imagefold="../templates/".$fold."/images";
if($step=="upfile"){
$pic=$_FILES["jpg"];
if($pic["size"]>0){
UploadTemp($pic["tmp_name"],$pic["type"],$pic["name"],$pic["size"],$openfold);
}else{
err($strDownNotice9,"tempftp.php","");
}
}
if($step=="upimg"){
$pic=$_FILES["jpg"];
if($pic["size"]>0){
UploadTemp($pic["tmp_name"],$pic["type"],$pic["name"],$pic["size"],$imagefold);
}else{
err($strDownNotice9,"tempftp.php","");
}
}
if($step=="delimg"){
$fname=$_REQUEST["fname"];
if(!strstr($fname,"/") && file_exists($imagefold."/".$fname)){
unlink($imagefold."/".$fname);
}
}
if($step=="delfile"){
$fname=$_REQUEST["fname"];
if(!strstr($fname,"/") && file_exists($openfold."/".$fname)){
unlink($openfold."/".$fname);
}
}
?>
<table width="98%" border="0" cellspacing="0" cellpadding="0" height="420" align="center">
<tr>
<td valign="top"> <br>
<table width="380" border="0" align="center" cellpadding="4" cellspacing="0" style="border:1px #cccccc solid" bgcolor="#f0f0f0" height="415">
<tr>
<td align="center" width="30" > </td>
<td align="center" height="30" > </td>
</tr>
<tr>
<td width="30" > </td>
<form method="post" action="tempftp.php" enctype="multipart/form-data">
<td height="50" > <?php echo $strTempFileUpload; ?>: <br>
<input type="file" name="jpg">
<input type="submit" name="Submit" value="<?php echo $strHtmlFlashUpload; ?>">
<input type="hidden" name="step" value="upfile">
<input type="hidden" name="fold" value="<?php echo $fold; ?>">
</td>
</form>
</tr>
<tr>
<td height="60" > </td>
<form method="post" action="tempftp.php" enctype="multipart/form-data">
<td height="60" > <?php echo $strTempImgUpload; ?>: <br>
<input type="file" name="jpg">
<input type="submit" name="Submit2" value="<?php echo $strHtmlFlashUpload; ?>">
<input type="hidden" name="step" value="upimg">
<input type="hidden" name="fold" value="<?php echo $fold; ?>">
</td>
</form>
</tr>
<tr>
<td align="center" width="30" > </td>
<td align="center" > </td>
</tr>
</table>
</td>
<td width="600" valign="top"> <br>
<table width="600" border="0" cellspacing="1" cellpadding="2" bgcolor="cccccc">
<tr bgcolor="#f0f0f0">
<td><?php echo $strDownList4; ?></td>
<td bgcolor="#f0f0f0" width="60"><?php echo $strDownAddSize; ?></td>
<td bgcolor="#f0f0f0" width="130"><?php echo $strUptime; ?></td>
<td bgcolor="#f0f0f0" width="50"><?php echo $strDownList5; ?> </td>
<td bgcolor="#f0f0f0" width="50"><?php echo $strDelete; ?></td>
</tr>
</table>
<table width="600" border="0" cellspacing="0" cellpadding="0" >
<tr bgcolor="#ffffff">
<td colspan=4 height=3></td>
</tr>
</table>
<div id="Layer1" style="position:absolute; width:600px; height:390; z-index:1; overflow: auto;border:1px #cccccc solid; ">
<table width="100%" border="0" cellspacing="1" cellpadding="1" bgcolor="#FFFFFF" height=380>
<tr valign="top">
<td>
<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
<tr id="imgclose">
<td width="18" style="cursor:hand" onClick="imgclose.style.display='none';imgopen.style.display='block'; showimg.style.display='block'"><img src="images/plus.gif" width="18" height="18"></td>
<td width="18" style="cursor:hand" onClick="imgclose.style.display='none';imgopen.style.display='block'; showimg.style.display='block'"><img src="images/folder.gif" width="18" height="18"></td>
<td colspan="2" style="cursor:hand" onClick="imgclose.style.display='none';imgopen.style.display='block'; showimg.style.display='block'">images</td>
<td width="120"> </td>
<td width="120"> </td>
<td width="120"> </td>
</tr>
<tr id="imgopen" style="display:none">
<td width="18" style="cursor:hand" onClick="imgclose.style.display='block';imgopen.style.display='none'; showimg.style.display='none'"><img src="images/minus.gif" width="18" height="18"></td>
<td width="18" style="cursor:hand" onClick="imgclose.style.display='block';imgopen.style.display='none'; showimg.style.display='none'"><img src="images/folderopen.gif" width="18" height="18"></td>
<td colspan="2" style="cursor:hand" onClick="imgclose.style.display='block';imgopen.style.display='none'; showimg.style.display='none'">images</td>
<td width="120"> </td>
<td width="120"> </td>
<td width="120"> </td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center" id="showimg" style="display:none">
<?php
$handle=opendir($imagefold);
while ($filename = readdir($handle)) {
$nowfile=$imagefold."/".$filename;
if($filename!="." && $filename!=".." && $filename!="_notes" && !strstr($filename,"/") && !is_dir($nowfile)){
$fsize=ceil(filesize($nowfile)/1000);
$ftime=date("Y-m-d H:i:s",filemtime($nowfile));
$pageimg="page_blank.gif";
if(substr($filename,-4)==".gif"){
$pageimg="page_gif.gif";
}
if(substr($filename,-4)==".jpg"){
$pageimg="page_jpg.gif";
}
if(substr($filename,-4)==".swf"){
$pageimg="page_swf.gif";
}
if(substr($filename,-4)==".htm"){
$pageimg="page_htm.gif";
}
if(substr($filename,-5)==".html"){
$pageimg="page_htm.gif";
}
if(substr($filename,-4)==".css"){
$pageimg="page_css.gif";
}
?>
<tr>
<td width="18"><img src="images/line.gif" width="18" height="18"></td>
<td colspan="3">
<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center" >
<tr>
<td width="18"><img src="images/join.gif" width="18" height="18"></td>
<td colspan="2">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20"><img src="images/<?php echo $pageimg; ?>" ></td>
<td><?php echo $filename; ?></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
<td width="60"><?php echo $fsize; ?>KB</td>
<td width="130" style="padding-left:5px"><?php echo $ftime; ?></td>
<td width="39" style="padding-left:5px"> <a href="tempdl.php?step=downimg&fname=<?php echo $filename; ?>&fold=<?php echo $fold; ?>" target="down"><img src="images/down.gif" border="0"></a>
</td>
<td width="39" style="padding-left:10px"> <a href="tempftp.php?step=delimg&fname=<?php echo $filename; ?>&fold=<?php echo $fold; ?>"><img src="images/resycle.gif" border="0"></a></td>
</tr>
<?php
}
}
closedir($handle);
?>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
<?php
$handle=opendir($openfold);
while ($filename = readdir($handle)) {
$nowfile=$openfold."/".$filename;
if($filename!="." && $filename!=".." && $filename!="_notes" && !strstr($filename,"/") && !is_dir($nowfile)){
$fsize=ceil(filesize($nowfile)/1000);
$ftime=date("Y-m-d H:i:s",filemtime($nowfile));
$pageimg="page_blank.gif";
if(substr($filename,-4)==".gif"){
$pageimg="page_gif.gif";
}
if(substr($filename,-4)==".jpg"){
$pageimg="page_jpg.gif";
}
if(substr($filename,-4)==".swf"){
$pageimg="page_swf.gif";
}
if(substr($filename,-4)==".htm"){
$pageimg="page_htm.gif";
}
if(substr($filename,-5)==".html"){
$pageimg="page_htm.gif";
}
if(substr($filename,-4)==".css"){
$pageimg="page_css.gif";
}
?>
<tr >
<td width="18"><img src="images/join.gif" width="18" height="18"></td>
<td width="18"><img src="images/<?php echo $pageimg; ?>" ></td>
<td colspan="2"><?php echo $filename; ?></td>
<td width="60"><?php echo $fsize; ?>KB</td>
<td width="130" style="padding-left:5px"><?php echo $ftime; ?></td>
<td width="39" style="padding-left:5px"><a href="tempdl.php?step=downfile&fname=<?php echo $filename; ?>&fold=<?php echo $fold; ?>" target="down"><img src="images/down.gif" width="14" height="14" border="0"></a></td>
<td width="39" style="padding-left:10px"><a href="tempftp.php?step=delfile&fname=<?php echo $filename; ?>&fold=<?php echo $fold; ?>"><img src="images/resycle.gif" border="0"></a></td>
</tr>
<?php
}
}
closedir($handle);
?>
</table>
</td>
</tr>
</table>
</div>
</td>
</tr>
</table>
<?php
if($step=="upimg" || $step=="delimg"){
echo "<script>
imgclose.style.display='none';
imgopen.style.display='block';
showimg.style.display='block';
</script>";
}
?>
<iframe src='0.htm' name='down' height='1' width='1' scrolling='0' marginheight='0' frameborder='0'>IE</iframe>
</body>
</html>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -