Author Topic: Template Editor Multiple Replace  (Read 546 times)

Dzib

  • Newbie
  • *
  • Posts: 17
Hi,

Being quite new in MusicBee, I'm struggling to create custom weblinks with the template editor.
I try to replace some characters in the link : https://genius.com/$Replace(<Artist>-<Title> lyrics," ","-") wotks but I'd like also to remove apostrophes...
I can't find how to have multiple replaces.

Edit: I've tried with regex but looks like $rxreplace(<Title>, "\s+", "-") doesn't work

Thanks
Last Edit: January 19, 2023, 09:45:21 AM by Dzib

Mayibongwe

  • Sr. Member
  • ****
  • Posts: 1050
  • Heal The World
Welcome to the forum, Dzib,

Haven't tested it, but I don't see why a nested $Replace wouldn't work:

Code
https://genius.com/$Replace($Replace(<Artist>-<Title> lyrics," ","-"),"<apostrophe>",<nothing>)
Favourite tune at the moment:   Dearly Beloved by Yoko Shimomura from the Kingdom Hearts soundtrack