Replace Regex Values

I’m trying to replace values using a Text Replace and Regex. I have tested the Regex and it works regex testing but I am having trouble with make outputting the correct replacement.

{{replace(1.10 + 1.11 + 1.12; “/\b(Basic|Platinum|Premium)\b/g”; " $")}}

It should receive one of these lines and replace with with “Basic, Platinum, or Premium”. Currently, it is outputting the full line not the substring from the regex.

(Included) - Basic Package: Projector & screen, one (1) handheld/lavalier microphone, sound system with mixer, and computer audio hookup.($375)
($375) - Premium Package: Projector & screen, two (2) handheld/lavalier microphone, sound system with mixer, and computer audio hookup.
($1075) - Platinum Package: Projector & screen, four (4) handheld/lavalier microphone, small sound system, and computer audio hookup.

You are replacing the match.

So you are matching /\b(Basic|Platinum|Premium)\b/g and replacing it with a $.


What you want to do is replace (remove) everything except Basic|Platinum|Premium, with an emptystring.


samliewrequest private consultation

Join the Make unofficial Discord server!


Samliew – Thank you for being such a supporter and help on the community. You have answered a lot of my questions and I appreciate that.

I understand what you’re saying about the replace it was finding what I needed, but I needed to replace it. I updated the Regex but now I am getting the result the following results “$Basic$”

How would I get rid of the “$”

I figured it out, I need to replace it with Empystring. I had tried leaving it blank and then it wasn’t replaced. By putting the “$” I was telling to replace the regex with those.

This was the correct way to do it.