develooper Front page | perl.beginners | Postings from March 2002

Re: regex question

Thread Previous
From:
victor
Date:
March 13, 2002 02:20
Subject:
Re: regex question
Message ID:
3C8F270F.7D094603@outblaze.com
Try this regexp.

s/###.*?###//g;



maasha@image.dk wrote:

> hi
>
> i have a long text file. in this text file several strings of the form:  ### filename.jpg ### are embedded.
>
> how should a regex look that takes following:
>
> <text before> ### filename.jpg ### <text after>
>
> and returns
>
> <text before> <text after>
>
> and the filename.jpg saved in a $
>
> :o)
>
> martin
> --
>
> --
> To unsubscribe, e-mail: beginners-unsubscribe@perl.org
> For additional commands, e-mail: beginners-help@perl.org


Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About