If you need to insert an image or other HTML content within your form, Gravity Forms makes the process easy and painless with the HTML field. Here’s how to do it.
- First, add an HTML field to your form where you want the custom content to go.
- Next, click on the HTML field that you just added to open up the field’s settings.
- Within the Content setting on the field, enter in any HTML content that you want to display.
- Save the form and access the form. You should now see your HTML content displaying correctly.
For example, if you want to embed an image within the form (ie: add a profile picture), you would enter the following:
<img src="https://example.com/wp-content/uploads/2020/02/my_image.jpg" alt="Profile photo" />
If you wanted to embed JavaScript into the form, you would do so like this:
<script> function myCustomJs() { return true; } function myCustomJs(); </script>