RE: [PHP] removing html...

2002-07-27 Thread John Holmes
> I have search around on google/php.net to try and find a way to remove > , everything above , and everything below it in a html page. FYI on the two methods I suggested: preg_match("/(.*)<\/body>/i",$html_text,$matches); eregi("(.*)",$html_text,$matches); Preg vs. Ereg name

RE: [PHP] removing html...

2002-07-27 Thread John Holmes
Or... preg_match("/(.*)<\/body>/i",$html_text,$matches); ---John Holmes... > -Original Message- > From: JJ Harrison [mailto:[EMAIL PROTECTED]] > Sent: Saturday, July 27, 2002 9:41 AM > To: [EMAIL PROTECTED] > Subject: [PHP] removing html... > > Hi, > > I have search around on google/p

RE: [PHP] removing html...

2002-07-27 Thread John Holmes
Use a regular expression. Something like this should work. eregi("(.*)",$html_text,$matches); $matches[1] should contain the text you are after. ---John Holmes... > -Original Message- > From: JJ Harrison [mailto:[EMAIL PROTECTED]] > Sent: Saturday, July 27, 2002 9:41 AM > To: [EMAIL PR

Re: [PHP] Removing HTML codes using regexp

2001-02-25 Thread Simon Garner
From: "Toke Herkild" <[EMAIL PROTECTED]> > What if I want to replace all html codes from a string ? > I've tried using : > > $myString = preg_replace('/<*>/, '', $myString); > but that deletes all string... ( or everything from first '<' ) ... > > Toke Herkild... > > Try striptags() http: