I’m collecting emails in Gravity forms and need to use that email in a URL and also display in the front-end. How can I encode the email for URLs, but keep it unencoded for display? Or, is this not necessary?

My use case is this:

* User A fills out a registration form with their email address
* User B needs to fill out a separate form evaluating registered users (User A)
* User B sees [site.com/[email protected]]), where this URL is programmatically generated from the User A input.
* User B clicks the link, and User A’s email is automatically populated in the form to ensure attribution is correct.

I’m using Gravity Forms, and because the value is saved as [[email protected]](mailto:[email protected]), the URL generated will have @ and not %40.

At present, the form successfully populates the email value from the URL parameter using the above URL with an @, but I would have assumed it should be encoded.

Might this be problematic? Any advice on addressing this if it is an issue to address?

Thanks!

1 Comment

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer