2014-08-14 PHPあれこれ PHP ファイルダウンロード機能 <?php $full_path = ファイルへの絶対パス; $file_name = ファイル名; header('Content-Type: application/octet-stream'); header('Content-Length: '.filesize($full_path)); header('Content-disposition: attachment; filename="'.$file_name.'"'); readfile($full_path);