This is a discussion on regexp help... within the PHP General forums, part of the PHP Programming Forums category; Hi all, I have a string that for all practical purposes should probably be a list (array). I need one ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Hi all,
I have a string that for all practical purposes should probably be a list (array). I need one line from the string and need to send the rest to /dev/null. The string starts: HTTP/1.1 200 OK Date: Tue, 22 Jul 2003 01:34:12 GMT Server: Apache/1.3.27 (Unix) mod_jk/1.1.0 mod_ssl/2.8.12 OpenSSL/0.9.6g Set-Cookie: JSESSIONID=mngtpma6i1;Path=/Interface Connection: close Content-Type: text/html;charset=ISO-8859-1 <?xml version="1.0"?> blah blah blah </shipment> The String ends on the line above (white space line). If I'm not mistaken the blank lines are actually a combo of unix and dos line returns. any help is much appreciated. thanks, |
|
|||
|
I guess I should point out that the line i want is the XML line
'<?xml......' On Monday, July 21, 2003, at 11:44 AM, Doug La Farge wrote: > Hi all, > > I have a string that for all practical purposes should probably be a > list (array). I need one line from the string and need to send the > rest to /dev/null. > > The string starts: > HTTP/1.1 200 OK > Date: Tue, 22 Jul 2003 01:34:12 GMT > Server: Apache/1.3.27 (Unix) mod_jk/1.1.0 mod_ssl/2.8.12 OpenSSL/0.9.6g > Set-Cookie: JSESSIONID=mngtpma6i1;Path=/Interface > Connection: close > Content-Type: text/html;charset=ISO-8859-1 > > > > > > > > > > > <?xml version="1.0"?> blah blah blah </shipment> > > > > The String ends on the line above (white space line). > > If I'm not mistaken the blank lines are actually a combo of unix and > dos line returns. > > any help is much appreciated. > > thanks, |