Tag: header

Force Download Dialog with PHP using octect-stream

Use this code to force a download of any type of content with PHP header(“Content-type:application/octect-stream”); header(‘Content-Disposition: attachment; filename=filename_’ . date(‘Y-m-d’)…

Get URL Headers from Linux Command Line

Show the headers of an URL from the command line. This will need perl, lwp installed on the system. lwp-request…

301 Redirect using PHP

301 Redirect using PHP header (‘HTTP/1.1 301 Moved Permanently’); header (‘Location: ‘.$new_location);

Get URL Headers using CURL

Show the headers of an URL using Curl curl http://example.com -I