手机
当前位置:查字典教程网 >编程开发 >php教程 >一个程序下载的管理程序(三)
一个程序下载的管理程序(三)
摘要://后台程序sign.php源代码如下:

//后台程序sign.php源代码如下:

<?require("../opendata.php");?>

<?

if($action=="sign")

{

if($say==""||$title==""||$url==""||$size=="")

{

header("location:../message.php?message=资料不完整&redirect=download/download.php?page=0%26action=publish");

break;

}$say=htmlspecialchars($say);

$title=htmlspecialchars($title);

$say=str_replace(" "," ",$say);

$say=nl2br($say);

$now_time=getdate();

$ttime=$now_time["year"]."-".$now_time["mon"]."-".$now_time["mday"]." ".$now_time["hours"].":".$now_time["minutes"].":".$now_time["seconds"];

$str="insert into download (title,say,click,ttime,url,size,type) values ('".$title."','".$say."',0,'#".$ttime."#','".$url."','".$size."',".$type.")";

mysql_query($str,$cn);

header("location:download.php?page=0&action=show");

}

if($action=="download")

{

mysql_query("update download set click=click+1 where id=".$id,$cn);

?>

<?

header("Content-type: text/html");

if(header("location:$url"))

echo "error";

?>

<html>

<p align="center"><a href="<?=$url?>">如果你的浏览器没有弹出下载窗口,请点这里</a></p>

<p align="center"><a href="javascript:self.close()">关闭窗口</a></p>

<p></p>

</html>

<?}?>

<?if($action=="mail")

{

mail("khj99@163.net","该链接有问题,请更正","id=$id;程序名=$title;类别=$type","From:khj99@163.netnReply-To:khj99@163.netn");

header("location:download.php?action=show&type=$type");

}

?>

【一个程序下载的管理程序(三)】相关文章:

PHP程序员使用最多的五个工具

一个高ai的分页函数和一个url函数

15个小时----从修改程序到自己些程序

PHP使用者状态管理功能的应用

多数据表共用一个页的新闻发布

VFP与其他应用程序的集成

PHP+MYSQL的文章管理系统(二)

一个简单的自动发送邮件系统(一)

PHP输出一个等腰三角形的方法

一个多文件上传的例子(原创)

精品推荐
分类导航