Page 1 of 1

Breaking the ice . . .

Posted: Mon May 17, 2004 5:35 pm
by GreyHead
I guess that there has to be a first post here.

I tried to use Easy Pattern helper yesterday and ran into blank. I tried the Reference but while I could see the bits of what I wanted to do I couldn't work out how to srting them together.

I'm trying to change the header blocks in a whole bunch of about 500 php files. With plain text lines this works fine. Then I came to this:
// $Id: index.php,v 1.4 2004/05/16 14:04:19 greyhead Exp $
-where the blue bit is variable. That I want to replace with this:
// $Id: index.php,v 1.4 2004/05/16 14:04:19 greyhead Exp $
I could find the string OK, but completely failed to get groups capture to work :-(


Posted: Wed May 19, 2004 1:55 pm
by DataMystic Support
Hi Bob,

I guess the obvious question is- what is your EasyPattern?

And what perl regex did EPHelper convert it to? Are you using v1.3?

Posted: Thu May 20, 2004 12:31 am
by Guest
Are you using v1.3?
No, I was on 1.1 - got the 1,3 update e-mail this morning.

Using 1.3 I got it to work OK . . .

Code: Select all

// $Id:[(oneOrMore chars)1]$
worked like a dream.


Posted: Thu May 20, 2004 9:48 am
by DataMystic Support
Great! The handling of [char] was broken in v1.1.

You can also capture text in a more natural way using

Code: Select all

// $Id:[capture(oneOrMore chars)]$
rather than using ()1