Regex problem..

Gregory Machin gregory.machin at gmail.com
Mon Jul 25 19:52:53 UTC 2005


On 7/25/05, Paul Howarth <paul at city-fan.org> wrote:
> On Mon, 2005-07-25 at 21:45 +0200, Gregory Machin wrote:
> > Hi.
> >
> > Please could you advise me...
> > I have php pages that are stored in a mysql database, that will later
> > be imported into a cms
> > I want to use mysql's regex funtion to remove unwanted php code and
> > update links to images
> > and urls.
> >
> > But i cant seem to get my brian around the regex part ...
> >
> > i want to remove the header include <?php require("./include/header1");?>
> > i tried <\?php[^>][header1].*\?> , and other attempts but no luck ..
> > unfortunetly i can do a normal string replace because of varations,in
> > the code ...
> 
> [header1] is a character class containing the following letters:
> 
> a d e h r 1
> 
> I guess that's not what you wanted really.

I want to remove the php tags and code where the string header1 is present..


> Paul.
> --
> Paul Howarth <paul at city-fan.org>
> 
> --
> fedora-list mailing list
> fedora-list at redhat.com
> To unsubscribe: http://www.redhat.com/mailman/listinfo/fedora-list
> 


-- 
Gregory Machin
greg at linuxpro.co.za
gregory.machin at gmail.com
www.linuxpro.co.za
Web Hosting Solutions
Scalable Linux Solutions 
www.iberry.info (support and admin)
www.goeducation (support and admin)
+27 72 524 8096




More information about the fedora-list mailing list