# Removing an HTML Link from the Lyrics

**URL:** https://community.mp3tag.de/t/removing-an-html-link-from-the-lyrics/13343
**Category:** Support
**Created:** [April 20, 2012, 2:20am UTC](https://community.mp3tag.de/t/removing-an-html-link-from-the-lyrics/13343 "2012-04-20T02:20:13Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![warthogmadman987](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/w/f9ae1b/32.png) [@warthogmadman987](https://community.mp3tag.de/u/warthogmadman987)
#### Post date: [April 20, 2012, 2:20am UTC](https://community.mp3tag.de/t/removing-an-html-link-from-the-lyrics/13343/1 "2012-04-20T02:20:13Z")

</div>

New poster here, So please be patient with me.

I don't have a ton of scripting experience but am willing to learn.

I have a lot of lyrics that I had imported by some software. This software grabbed from some database that put an html link into the middle of the lyrics.

I have been trying to make an action using the Replace function as well as the Replace with regular expression function using the UNSYNCEDLYRICS field. The string I want to remove is contained in brackets. I'm just not getting it to work right. I've tried learning from some examples on this site, but have been unsuccessful. As an example, below is a cut and paste of a song:

Say after me,  
It's no better to be safe than sorry.   
[Lyrics from: [http://www](http://www). Lyricsfreak. Com/a/a+ha/take+on+me\_20001902. Html ]  
Take on me (take on me)

Is there a way to remove the 3rd line?

Thanks for all your help.

---

<div class="post-metadata">

### Author: ![ohrenkino](https://community.mp3tag.de/user_avatar/community.mp3tag.de/ohrenkino/32/4843_2.png) [@ohrenkino](https://community.mp3tag.de/u/ohrenkino)
#### Post date: [April 20, 2012, 4:18am UTC](https://community.mp3tag.de/t/removing-an-html-link-from-the-lyrics/13343/2 "2012-04-20T04:18:10Z")

</div>

> [@warthogmadman987](#):
>
> ... As an example, below is a cut and paste of a song:
> 
> Say after me,  
> It's no better to be safe than sorry.   
> [Lyrics from: [http://www](http://www). Lyricsfreak. Com/a/a+ha/take+on+me\_20001902. Html ]  
> Take on me (take on me)
> 
> Is there a way to remove the 3rd line?
> 
> Thanks for all your help.

Create an action of the type Replace with regular expression for the field UNSYNCEDLYRICS.  
Enter as search string:  
(._)[._](.\*)  
enter as format string:  
$1 $2

---

<div class="post-metadata">

### Author: ![warthogmadman987](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/w/f9ae1b/32.png) [@warthogmadman987](https://community.mp3tag.de/u/warthogmadman987)
#### Post date: [April 20, 2012, 4:45am UTC](https://community.mp3tag.de/t/removing-an-html-link-from-the-lyrics/13343/3 "2012-04-20T04:45:44Z")

</div>

> [@ohrenkino](#):
>
> Create an action of the type Replace with regular expression for the field UNSYNCEDLYRICS.  
> Enter as search string:  
> (._)[._](.\*)  
> enter as format string:  
> $1 $2

Thank You! Thank worked. Now I'm gonna have to try and figure out how it worked to understand.

---

<div class="post-metadata">

### Author: ![ohrenkino](https://community.mp3tag.de/user_avatar/community.mp3tag.de/ohrenkino/32/4843_2.png) [@ohrenkino](https://community.mp3tag.de/u/ohrenkino)
#### Post date: [April 20, 2012, 8:01am UTC](https://community.mp3tag.de/t/removing-an-html-link-from-the-lyrics/13343/4 "2012-04-20T08:01:22Z")

</div>

> [@warthogmadman987](#):
>
> Thank You! Thank worked. Now I'm gonna have to try and figure out how it worked to understand.

Oh well: the dot means "any character".  
The asterisk means "any number of it"  
The round brackets mean "treat this as a unit" - these units in brackets can later be addressed by a numbered variable: the first set of bracket becomes $1, the second $2 etc ...  
As the square bracket [ has a special meaning in the regular expressions but you want to tread it as a literal for the delimiter it has to be escaped with the backslash.  
So in plain language the search string reads:  
structure the whole of the filed into one part before an opening square bracket, one between and one following the closing square bracket and then transfer only the parts before an after back to the field.

---

<div class="post-metadata">

### Author: ![stevehero](https://community.mp3tag.de/user_avatar/community.mp3tag.de/stevehero/32/337_2.png) [@stevehero](https://community.mp3tag.de/u/stevehero)
#### Post date: [April 20, 2012, 2:56pm UTC](https://community.mp3tag.de/t/removing-an-html-link-from-the-lyrics/13343/5 "2012-04-20T14:56:17Z")

</div>

> [@warthogmadman987](#):
>
> Thank You! Thank worked. Now I'm gonna have to try and figure out how it worked to understand.

Another way which might be safer is as looks for the 'html]' in the string and deletes everything inside the ''

Otherwise the one you have will delete [Anything inside square/closed brackets]

_Action type:_ **Replace with regular expression**  
_Field:_ **UNSYNCEDLYRICS**  
_Regular expression:_ **[.+html[^]]]**  
_Replace matches with:_

[] case-sensitive comparison

See attached jpeg for explanation.

 ![](https://community.mp3tag.de/uploads/default/original/2X/9/95d013d2d4287f32e26eaa376f316a83a6f3431e.jpg)

---

<div class="post-metadata">

### Author: ![system](https://community.mp3tag.de/uploads/default/original/2X/c/ce7035d426cb755a7916793326d23b465222a407.png) [@system](https://community.mp3tag.de/u/system)
#### Post date: [February 9, 2026, 12:23pm UTC](https://community.mp3tag.de/t/removing-an-html-link-from-the-lyrics/13343/6 "2026-02-09T12:23:48Z")

</div>


