To make modal popup on pageload, simply add the open="true" to the {modal} tag.

And if you do not want to show the actual modal link in the content of your page, then simply don't place any text between the {modal} tags, like:

{modal url="my/url" open="true"}{/modal}

The syntax for the modal popup you can see on the Examples Page looks like:

{modal html="Yes, you can also make modal popups show on page load!" title="Welcome to the Modals Demo" open="true" autoclose="5000"}{/modal}

In alternative, you can also assign an id attribute to the {modal} tag with your custom ID, and then make the modal automatically open via URL.

{modal url="my/url" id="my_example"}{/modal}

You can then simply add a ?modal=my_example parameter to the URL of the page containing the modal to make it open on pageload. Click here to try it out.

Open with a delay

Maybe you want the modal popup to open after a few seconds. No problem, Modals can do that too.

Simply add a delay attribute to the tag and give the time value in milliseconds.

So to open a modal popup 7.5 seconds after the page has loaded, do:

{modal url="my/url" open="true" delay="7500"}{/modal}

Show only once

To make a modal popup only show once, you can instead use the attribute open="once", like:

{modal html="This modal will only show once" open="once"}{/modal}

By default, Modals will keep track of the count via a site wide cookie. If you want this count to be based on the individual page visits, then you can change that in the Modals plugin settings. You can also choose to base the count on the site wide session count instead.

Show on specific page loads

You can also tell Modals to show the modal on specific pageloads or a specified range of visits, using the open attributes. For instance, to show a modal on the second, third and fourth page load, you can do:

{modal html="This modal will show on visit 2, 3 and 4" open="2,3,4"}{/modal}

or:

{modal html="This modal will show on visit 2, 3 and 4" open="2-4"}{/modal}

If you want a modal to pop up on the first 5 visits and on visit 10, 15 and 20, you can do:

{modal html="This modal will show on visits, 1-5, 10, 15 and 20" open="1-5,10,15,20"}{/modal}

By default, Modals will keep track of the count via a site wide cookie. If you want this count to be based on the individual page visits, then you can change that in the Modals plugin settings. You can also choose to base the count on the site wide session count instead.