Hi,
I would like to find the appropriate regex to search and replace in a source code of an html file :
- search simultaneously 12,50 and 12.50
- and replace it simultaneously respectively by (for instance) 12,80 and 12.80
Thank you in advance for any help.
Patrick
search and replace data with coma or dot
Re: search and replace data with comma or dot
Find:
(\d+)([\.,])(\d+)
Replace by:
$1$280
Would that do?
Perhaps {$1}{$2}80.
You could also use "12[.,](\d+)" and "12$180" or the form that does work...
(\d+)([\.,])(\d+)
Replace by:
$1$280
Would that do?
Perhaps {$1}{$2}80.
You could also use "12[.,](\d+)" and "12$180" or the form that does work...
Re: search and replace data with coma or dot
Hi,
Thank you for the prompt reply.
I do not understand how (\d+)([\.,])(\d+) can search specifically for 12.50 and 12,50 ?
Thank you in advance,
Patrick
Thank you for the prompt reply.
I do not understand how (\d+)([\.,])(\d+) can search specifically for 12.50 and 12,50 ?
Thank you in advance,
Patrick
Re: search and replace 12 50 with comma or dot
Specifically 12 50 with comma or dot = "12, then comma or dot, then 50".
Find:
12([\.,])50
Replace by:
12$180
Find:
12([\.,])50
Replace by:
12$180
Re: search and replace data with coma or dot
Thank you !
It does work well with Tewt Crawler
It does work well with Tewt Crawler