PHP 强制下载文件代码
网络整理 - 08-29
<?php
$filename = '1.png';
header("Content-Type: application/force-download");
header('Content-Disposition: attachment; filename="'.$filename.'"');
echo $filename;
?>
<?php
$filename = '1.png';
header("Content-Type: application/force-download");
header('Content-Disposition: attachment; filename="'.$filename.'"');
echo $filename;
?>