note 42099 deleted from function.explode by nlopess

From: Date: Tue, 04 May 2004 13:22:27 +0000
Subject: note 42099 deleted from function.explode by nlopess
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-69196@lists.php.net to get a copy of this message
Note Submitter: ---- If headers are being shown when echoing a page retrieved from a remote host, you can remove them like this: <? $tmp = explode("\r\n\r\n",$retrieved_page,2); $retrieved_body = $tmp[1]; ?> The reason this happens is because you can only send out one set of headers, so unless you replace the headers your server sends out with the ones retrieved from the remote server, the second set will be displayed in the users browser. Another way, as posted by 'markus dot welsch at suk dot de' is to use 'trim'. I have not compared the execution time of either method. -- The Brain http://www.webmasterbrain.com/

« previous php.notes (#69196) next »