Re: Extracting HTML from a file

From: Date: Tue, 20 May 2003 08:12:32 +0000
Subject: Re: Extracting HTML from a file
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-148263@lists.php.net to get a copy of this message
On Tuesday 20 May 2003 15:37, Shaun wrote: > using the following code I am extracting any HTML from a file which occurs > between the two tags <!-- beginIsEditable --> and <!-- endIsEditable --> > > preg_match_all('|<!-- beginIsEditable -->(.*?)<!-- endIsEditable -->|is', > implode('', file('../'.$_GET[file_name])), > $matches = array(), > PREG_SET_ORDER); > $script = stripslashes(htmlentities($matches[0][0])); > > How can I modify this so that it extracts the HTML between these tags, > rather than the HTML including these tags? print_r($matches) -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * ------------------------------------------ Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general ------------------------------------------ /* Your mail is being routed through Germany ... and they're censoring us. */

« previous php.general (#148263) next »