Perl-Sensitive Sunglasses | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
Hi,
just how powerful is this option? I wish to edit a bunch of .html files inside a directory and basically searching and replacing html coding. To do this, I plan on using: perl -pi -e 's/http://www.mydomain.com/script.pl?key=3/http://www.mydomain.com/script.pl?key=4/' /home/name/public_html/html/*.html Now would the above work if I was to run the command via cron job on a shared hosting environment? I also may be replacing html with quotes inside the search pattern. Do I cancel those out like I would when writing in perl? For ex:
I'm going to do this later on with trial and error, but want to make sure if I'm on the right track with what I'm trying to do. Thanks. In reply to Perl command line search and replace by Anonymous Monk
|
|