Chinaunix首页 | 论坛 | 博客
  • 博客访问: 555495
  • 博文数量: 34
  • 博客积分: 10171
  • 博客等级: 上将
  • 技术积分: 1365
  • 用 户 组: 普通用户
  • 注册时间: 2004-11-09 13:13
文章分类

全部博文(34)

文章存档

2011年(1)

2009年(20)

2008年(13)

我的朋友

分类: LINUX

2009-09-16 16:08:12

<?  #get.php
    $get_url = urldecode($_GET[url]);
    $file_name = basename($get_url);
    header("Content-Transfer-Encoding: binary");
    header('Content-Type: application/octetstream');
    header('Content-Disposition: attachment; filename='.$file_name);
    header("Connection: close");
    readfile($get_url);
?>

下载资源如 .mp3,jpg 

以直接点击就能“另存为”的方式

=http://control.cublog.cn/images/top_left.gif

 

阅读(722) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~