Adding .html text extension to html code...

A swapping-ground for Regular Expression syntax

Adding .html text extension to html code...

Postby taltools » Sat May 28, 2016 8:07 pm

Hi there,

i have a lot of HTML code (thousands of pages) which some of the URLs in the code were created without the '.html' extension.
i need to add them the extentions (not to the files, to the text code),

for example:
<a href="red-imported-fire-ant"
To be replaced with:
<a href="red-imported-fire-ant.html"

while the 'red-imported-fire-ant' text is changing of course.

can this be done?

thank you!
Posts: 1
Joined: Sat May 28, 2016 7:57 pm

Re: Adding .html text extension to html code...

Postby therube » Sun May 29, 2016 11:11 am

BRU is used to rename file names, not to change file contents.

You want to find a "Search and Replace" type program that will change file contents.

(I'm not particularly familiar with any of these.)
What are good grep tools for Windows?
Posts: 317
Joined: Mon Jan 18, 2016 6:23 pm

Return to Regular Expressions