List out different arguments in PHP header function?
Answer Posted / sivasankar.p
header —
Send a raw HTTP header
syntax-
void header ( string $string [, bool $replace [,
int $http_response_code ]] )
ex:
<?php
// We'll be outputting a PDF
header('Content-type: application/pdf');
// It will be called downloaded.pdf
header('Content-Disposition: attachment;
filename="downloaded.pdf"');
// The PDF source is in original.pdf
readfile('original.pdf');
?>
| Is This Answer Correct ? | 9 Yes | 3 No |
Post New Answer View All Answers
What is new keyword in php?
How to process the uploaded files?
What is use of echo in php?
What is baseurl?
What are php magic quotes?
How to get number of elements in an array?
Explain about the connective abilities of the PHP?
What PHP stands for?
What is in a cookie?
What is difference between session_unset and session_destroy?
What are sql functions?
Tell me what does the scope of variables means?
Is empty in excel?
Which is better mysql or sql?
What is the use of offset in mysql?