note 99507 added to function.header

From: Date: Fri, 20 Aug 2010 18:00:36 +0000
Subject: note 99507 added to function.header
Groups: php.notes 
Request: Send a blank email to php-notes+get-171892@lists.php.net to get a copy of this message
About Cody G.'s research: Thanks a lot for your findings. I only wanted to add that it's not the more efficient way to use an include() function for the only purpose to output the content of a file. As it's well described and documented for example in this webpage: http://www.raditha.com/wiki/Readfile_vs_include , the readfile() function - or if you prefer, the fpassthru() function, but this one asks you to wrap it by the opening and the closing of the file - is way faster, and uses a lot less memory, as it only asks to the server to make what is its job, after all: to output a text file. This way the content is not loaded into the php program memory, and the sending is managed by the http server which has been highly optimized for this simple task. (I apologize if my participation is seen as out of the subject strictly relative to the header() function). ---- Server IP: 69.147.83.197 Probable Submitter: 87.246.62.34 ---- Manual Page -- http://www.php.net/manual/en/function.header.php Edit -- https://master.php.net/note/edit/99507 Del: integrated -- https://master.php.net/note/delete/99507/integrated Del: useless -- https://master.php.net/note/delete/99507/useless Del: bad code -- https://master.php.net/note/delete/99507/bad+code Del: spam -- https://master.php.net/note/delete/99507/spam Del: non-english -- https://master.php.net/note/delete/99507/non-english Del: in docs -- https://master.php.net/note/delete/99507/in+docs Del: other reasons-- https://master.php.net/note/delete/99507 Reject -- https://master.php.net/note/reject/99507 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#171892) next »