Barti wrote:
Actually, why don't you show us the code you have so far?
Then it would be much easier to find and fix any problems with it.
To tell you the truth I have no code.
I need in my php files change this.
I do not want to do that one by one (too many hours!) and
I don't know perl at all but I know that perl with find can do that
I have somethig like this to change one word in another
find -type f -name '*.*' -exec perl -pi -e 's/word/anotherword/;' {}
\; but this situation is diffrent because I need find strings match
pattern[*] where * is wahtever and change into ['*']
Again, "perldoc perlretut" is your friend.
<quote>
Extracting matches
The grouping metacharacters "()" also serve another completely different
function: they allow the extraction of the parts of a string that
matched. This is very useful to find out what matched and for text
processing in general. For each grouping, the part that matched inside
goes into the special variables "$1", "$2", etc. They can be used just
as ordinary variables:
# extract hours, minutes, seconds
$time =~ /(\d\d):(\d\d):(\d\d)/; # match hh:mm:ss format
$hours = $1;
$minutes = $2;
$seconds = $3;
</quote>
Just use that $1, $2, $3, ... in the substitution string.
jue