We've retired the forum in favor of GitHub Discussions.

New conversations can be started on GitHub. Existing conversations will remain for a while longer.

Head over to GitHub →

How to strip out all white space from a variable

Kelly January 19, 2017 by Kelly

If I'm using a global variable for a telephone number and I want to have something like:

<p>Billing: <a href="tel:{{ billing_number }}">{{ billing_number }}</a></p>

Is there a way to strip out the space that might be shown within the billing phone number for the variable within the a tag?

The variable has this type of format. (xxx) xxx-xxxx

When used in the link, I'm trying to not have %20 shown in the link - representing the extra spaces.

>>>>>>> Unanswered <<<<<<<
2 Replies