Create WordPress Forms that Open and Close Automatically

gator forms logo

Gator Forms is our favorite WordPress forms plugin.

One of the reasons we like it so much is that it has a wide range of display options. Gator Forms doesn’t require you to put your form inside a Post or a Page. You can show your forms in pop-ups, tabs, accordions, lightboxes and other effects.

In this guide, I’m going to show how you to create a form that automatically opens and closes for visitors.

Before You Start

The Auto Open feature

Let’s show you how to automatically open your form inside a pop-up.

  • Go to your WordPress admin area and create a new form.
  • Select the Hidden before the opening option.
  • Click the “Advanced” button.

hidden

  • Click the On scroll radio button.
  • Set the Auto-open delay [ms] setting to 200 (a fifth of a second).
  • Leave the Auto-open count setting with the default value of 1 (we’ll come back to this later).
  • Leave Cookie lifetime [days] intact.

05

  • Click Save.
  • Open the page where your form is located.
  • Scroll down and the form will be displayed.
  • Close the form.
  • Refresh the page and scroll down again. Your form will automatically open:

06

One thing to note … this feature can be hard to test, depending how you set the Auto-open count feature. We set the Auto-open count setting to 1 which means you will only see the form pop-up one time.

  • You can increase this value in order to let the form auto-open determined number of times.
  • You can even set it to 0 if you want the form to appear every time a user scrolls down.

The On exit radio button presents the same settings. This option displays the form when the user moves the mouse towards the close tab or close browser buttons.

This is useful for example in landing pages. If the potential customer wants to leave, you still have a chance to get their email address.

The Auto-close Feature

This option allows you to decide whether the form will be closed if the form submission is successful.

Leave this set to No if you don’t want the form to close after sending the answer e-mail.

  • Set the Auto-close option to On mail success.
  • Set Disable manual closing of Lightbox to Yes.
  • Click Save.

07

  • Refresh the page.
  • Take a look at the form.

The “x” icon on the top right of the form has disappeared and there’s no way to close the form.

The form will only go away if you submit it or refresh the page. This forces the user to enter their information in order to access the screen. This might be annoying, but you could also use this is a gateway for valuable content.

08

Author

  • Jorge Montoya

    Jorge lived in Ecuador and Germany. Now he is back to his homeland Colombia. He spends his time translating from English and German to Spanish. He enjoys playing with Drupal and other Open Source Content Management Systems and technologies.

    View all posts
0 0 votes
Article Rating
Subscribe
Notify of
guest

0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x