There are links on the page.
It is necessary to remove the start and end slash trim ($ str, '/') in the link attributes, change the slashes to the hyphen (which are in the link path), and add .html ...
I don't understand how to do it, I try to do regular expressions, but it doesn't work.
<p> <a title="fdfds" href="/contact/us" target="_self">click here</a> <a href="/back/us" title="fdsd" target="_self">click here</a> </p> It should look like this:
<p> <a title="fdfds" href="contact-us.html" target="_self">click here</a> <a href="back-us.html" title="fdsd" target="_self">click here</a> </p>