- Rongsen.Com.Cn 版权所有 2008-2010 京ICP备08007000号 京公海网安备11010802026356号 朝阳网安编号:110105199号
- 北京黑客防线网安工作室-黑客防线网安服务器维护基地为您提供专业的服务器维护,企业网站维护,网站维护服务
- (建议采用1024×768分辨率,以达到最佳视觉效果) Powered by 黑客防线网安 ©2009-2010 www.rongsen.com.cn
 
  
    
| 作者:黑客防线网安PHP维护基地 来源:黑客防线网安PHP维护基地 浏览次数:0 | 
这一节我们将dele.php和sys.php放上来. 
--------- 
//dele.php<html> 
<head> 
<title>删除留言</title> 
<style> 
<!-- 
A:link {text-decoration: none ; color:0000ff} 
A:visited {text-decoration: none; color:004080} 
A:active {text-decoration: none} 
A:hover {text-decoration: underline; color:ff0000} 
BODY {FONT-SIZE:10pt} 
TH {FONT-SIZE:10 pt} 
TD {FONT-SIZE: 10pt} 
--> 
</style> 
<meta http-equiv="Content-Type" content="text/html; charset=gb2312"> 
</head> 
<? 
require("sys.php"); 
if ($Submit) 
{ 
if ($password<>$managepwd) 
  {$errorm="<font color=red>密码错误</font>.无权操作..";} 
else  
{ 
$content=file($guestfile); 
$message=$content[$record-1]; 
$count=count($content); 
if ($dele=="delreply") 
     { 
     $replylen=strlen(strstr($message,"<!--reply>")); 
     $long=strlen($message); 
     $len=$long-$replylen; 
     $message=substr($message,0,$len); 
     } 
     else 
     {$message="";} 
//writefile 
$fp=fopen($guestfile,"w"); 
for ($i=0;$i<$count;$i++) 
  { 
  if ($i==($record-1)){$content[$i]=$message;} 
  fputs($fp,$content[$i],strlen($content[$i])); 
  }//end for 
fclose($fp); 
echo "<meta http-equiv=Refresh content="1;url=guest.php">"; 
exit; 
} 
}// end ifSubmit 
$content=file($guestfile); 
$message=$content[$record-1]; 
$found=ereg("<!--reply>",$message); 
?> 
<body bgcolor="#FFFFFF" background="back.gif"> 
<? include("head.htm"); ?> 
<table width="68%" border="1" cellpadding="5" align="center" cellspacing="0" bordercolor="#F2F2F2"> 
<form action=dele.php method=post> 
<? 
  if ($errorm) 
  { 
echo "<tr>";  
echo "<td height=27>$errorm</td>"; 
echo "</tr>"; 
  } 
| 我要申请本站:N点 | 黑客防线官网 | | 
| 专业服务器维护及网站维护手工安全搭建环境,网站安全加固服务。黑客防线网安服务器维护基地招商进行中!QQ:29769479 |