Re: search and replace code in php or html files

2006-05-06 Thread J.A. de Vries
On 2006-05-05 @ 18:48:36 (week 18) H.S. wrote: > Casey T. Deccio wrote: > > > > > find . -name "*.html" | xargs sed -i.bak -e > > 's/string_to_replace/replacement/g' > > > > Does something like this work? If your match pattern spans more than > > one line than you'll need a more complex script

Re: search and replace code in php or html files

2006-05-05 Thread H.S.
Casey T. Deccio wrote: > > find . -name "*.html" | xargs sed -i.bak -e > 's/string_to_replace/replacement/g' > > Does something like this work? If your match pattern spans more than > one line than you'll need a more complex script. > > Casey > > > For all cases so far, I haven't had any n

Re: search and replace code in php or html files

2006-05-05 Thread Joris Huizer
Casey T. Deccio wrote: On Fri, 2006-05-05 at 13:16 -0400, H.S. wrote: The problem is to change a particular link in all the pages. I assume the webpages were made using a template. If I were to search and replace a particular string with a the new desired one, I would be done. Could somebody su

Re: search and replace code in php or html files

2006-05-05 Thread Casey T. Deccio
On Fri, 2006-05-05 at 13:16 -0400, H.S. wrote: > The problem is to change a particular link in all the pages. I assume > the webpages were made using a template. If I were to search and replace > a particular string with a the new desired one, I would be done. Could > somebody suggest the best way

RE: search and replace code in php or html files

2006-05-05 Thread Gwenissia
It was generated by dreamweaver then - Dreamweaver prefixes the javascript functions it creates for rollover images with mm Regards, Pat -Original Message- From: news [mailto:[EMAIL PROTECTED] On Behalf Of H.S. Sent: 05 May 2006 18:45 To: debian-user@lists.debian.org Subject: Re: search

Re: search and replace code in php or html files

2006-05-05 Thread H.S.
Linas Žvirblis wrote: > > Check out "rpl" package. > I will take a look, thanks. > > See if it contains a "generator" meta tag. Other than that, sites made > with Frontpage will contain all sorts of errors, MS specific code etc. > This is not a scientific definition, but if it looks like cra

Re: search and replace code in php or html files

2006-05-05 Thread Linas Žvirblis
H.S. wrote: > The problem is to change a particular link in all the pages. I assume > the webpages were made using a template. If I were to search and replace > a particular string with a the new desired one, I would be done. Check out "rpl" package. > As an aside, given the webpage, is there an

Re: Search and Replace

1999-01-11 Thread Frank Barknecht
John Greer hat gesagt: // John Greer wrote: > I know that this is not Debian specific but I thought I would give it a > shot anyway. I need to search a series of files for a text string > (grep I know) and then I need to replace that string with another. Is > there a command or string of comm

Re: Search and Replace

1999-01-10 Thread Carey Evans
[EMAIL PROTECTED] (shaul) writes: > Are there www sites from where I can download introductory level texts for > these tools ? awk: info gawk (Install gawk package first) sed: man sed, under "SEE ALSO" Perl: http://language.perl.com/ Python: http://www.python.org/ or /usr/doc/python/html/tut/in

Re: Search and Replace

1999-01-10 Thread shaul
> sed was made for that. there are lots of other tools > that are more programming-oriented (awk, perl, python...); > sed is simple and a bit cryptic but good to get to know. > Are there www sites from where I can download introductory level texts for these tools ?

Re: Search and Replace

1999-01-08 Thread Alexander Kushnirenko
Hi, Yes there are quite a few ways to do that, another example: GLOBAL REPLACE in the files: awk '{gsub("call", "mall", $0); print > FILENAME}' *.kumac change call to mall in all *.kumac files Word of CAUTION: If you process really big files you may run into trouble, that only part of your file

Re: Search and Replace

1999-01-08 Thread David Coe
sed was made for that. there are lots of other tools that are more programming-oriented (awk, perl, python...); sed is simple and a bit cryptic but good to get to know. John Greer wrote: > > I know that this is not Debian specific but I thought I would give it a > shot anyway. I need to searc

Re: Search and Replace

1999-01-08 Thread Jeff Noxon
On Fri, Jan 08, 1999 at 08:49:10AM -0700, John Greer wrote: > I know that this is not Debian specific but I thought I would give it a > shot anyway. I need to search a series of files for a text string > (grep I know) and then I need to replace that string with another. Is > there a command or

Re: Search and Replace

1999-01-08 Thread John Greer
I know that this is not Debian specific but I thought I would give it a shot anyway. I need to search a series of files for a text string (grep I know) and then I need to replace that string with another. Is there a command or string of commands that I can do this in? If this is possible it