代码如下:
$filename = '1.png';header("Content-Type: application/force-download");header('Content-Disposition: attachment; filename="'.$filename.'"');echo $filename;?>
来源: https://www.php1.cn/detail/php-94872c7cf5.html