faqts : Computers : Programming : Languages : PHP : Common Problems : HTTP Headers

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

8 of 18 people (44%) answered Yes
Recently 7 of 10 people (70%) answered Yes

Entry

When retrieving a file from a web server using fsockopen, what is the best way to remove the header?

Sep 21st, 2006 09:05
Prasanna Manian, Scott Reston,


hi,

 This is my way of cutting the headers & it's working...

function cutHeaders($str) {
	$strResponse = explode("\r\n\r\n",$str);
	return $strResponse[1];
}

$onlyResponse = cutHeaders($fullResponse);