Wednesday, May 1, 2024
 Popular · Latest · Hot · Upcoming
3
rated 0 times [  3] [ 0]  / answers: 1 / hits: 2726  / 2 Years ago, tue, march 1, 2022, 3:49:23

Is there a way to do this in Ubuntu? I've read it's possible in php, but I'm not familiar with php at all.


More From » html

 Answers
2

You could use sed for that, but it will only work for links that are in a single line in the html code.



Update:



Damn greedy regex! ;) This one should work now!



sed -i 's|<a[^>]+>|<a>|g' <the-html-file>


[#30984] Tuesday, March 1, 2022, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
hreadsoplet

Total Points: 220
Total Questions: 108
Total Answers: 105

Location: Serbia
Member since Fri, Jun 3, 2022
2 Years ago
;