note 71605 added to function.explode
| From: | (attatat) | Date: | Thu, 07 Dec 2006 12:32:32 +0000 |
| Subject: | note 71605 added to function.explode | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-120373@lists.php.net to get a copy of this message | ||
Was investigating long time how to split headers and response after got result from fsockopen().
The next piece of code saved me:
list($headers, $result) = explode("\n\r", $result, 2);
print $result;
EVEN
list($headers, $result) = explode("\n\r\n $result, 2);
print $result;
Previously I used \n\n and that did not work.
P.S.: I am working on paypal implementeation.
Thanks.
----
Server IP: 195.222.164.18
Probable Submitter: 217.65.211.78
----
Manual Page -- http://www.php.net/manual/en/function.explode.php
Edit -- https://master.php.net/note/edit/71605
Del: integrated -- https://master.php.net/note/delete/71605/integrated
Del: useless -- https://master.php.net/note/delete/71605/useless
Del: bad code -- https://master.php.net/note/delete/71605/bad+code
Del: spam -- https://master.php.net/note/delete/71605/spam
Del: non-english -- https://master.php.net/note/delete/71605/non-english
Del: in docs -- https://master.php.net/note/delete/71605/in+docs
Del: other reasons-- https://master.php.net/note/delete/71605
Reject -- https://master.php.net/note/reject/71605
Search -- https://master.php.net/manage/user-notes.php