Modal Window Onload

movieprodw used Ask the Experts™

I just want to have a modal window show an alert on page load.

Can you please tell me how to trigger this on page load.

<!-- Small modal -->
<button type="button" class="btn btn-primary" data-toggle="modal" data-target=".bs-example-modal-sm">Free Shipping</button>

<div class="modal fade bs-example-modal-sm" tabindex="-1" role="dialog" aria-labelledby="mySmallModalLabel">
  <div class="modal-dialog modal-sm">
    <div class="modal-content">
      Did you know if you purchase 4 or more, you qualify for free shipping!

Open in new window

Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Fixer of Problems
Most Valuable Expert 2014
That's normally done by putting an 'onload' in the body tag to call a JavaScript routine that opens it up.


Thanks, sorry for the delay, I lot track of this task and need to go back ans do it.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial