Help

The Community will be temporarily unavailable starting on Friday February 28. We’ll be back as soon as we can! To learn more, check out our Announcements blog post.

Prefill forms with the "&" character

Topic Labels: Formulas
Solved
Jump to Solution
1598 1
cancel
Showing results for 
Search instead for 
Did you mean: 
Jeff_Hladek
5 - Automation Enthusiast
5 - Automation Enthusiast

I am using a form with some prefilled fields. It works great as long as the item name doesn't include certain special characters. For instance, if it includes an "&" anything after the "&" won't be prefilled. So "Mop & Broom Holder" prefills as just "Mop". Some of the product names we have are a bit long, so it can be a pain to have to type everything out. I know why this is happening, but I'm wondering if there is a way to include the "&" in a url and have it be part of the prefilled information. 

This is the formula I am using in the button that leads to the form.

Form URL'&'?prefill_Name='&Item&'&prefill_Quantity='&{Received Qty}&'&prefill_Project+Tag='&{Project Tag}&'&prefill_Date+of+Update='&TODAY()

This is the URL that I get from that formula using the "Mop & Broom Holder" and an example
...prefill_Name=Mop+&+Broom+Holder=&prefill_Quantity=4&prefill_Project+Tag=ATN&prefill_Date+of+Update=2024-01-25T00%3A00%3A00.000Z
1 Solution

Accepted Solutions
Jeff_Hladek
5 - Automation Enthusiast
5 - Automation Enthusiast

 ðŸ™„

I figured this out like 5 minutes after posting this.

For anyone else running into this issue, the solution is to use ENCODE_URL_COMPONENT() in the formula. 
i.e ...?prefill_Name='& ENCODE_URL_COMPONENT(Item)&'...

This changes the URL to ...?prefill_Name=Mop+%26+Broom+Holder...

See Solution in Thread

1 Reply 1
Jeff_Hladek
5 - Automation Enthusiast
5 - Automation Enthusiast

 ðŸ™„

I figured this out like 5 minutes after posting this.

For anyone else running into this issue, the solution is to use ENCODE_URL_COMPONENT() in the formula. 
i.e ...?prefill_Name='& ENCODE_URL_COMPONENT(Item)&'...

This changes the URL to ...?prefill_Name=Mop+%26+Broom+Holder...