当前位置:Gxlcms > PHP教程 > PHP强制下载文件代码_PHP

PHP强制下载文件代码_PHP

时间:2021-07-01 10:21:17 帮助过:19人阅读

代码如下:

$filename = '1.png';
header("Content-Type: application/force-download");
header('Content-Disposition: attachment; filename="'.$filename.'"');
echo $filename;
?>

人气教程排行