-5

I want this modal load 5 second letter. How to set jquery time set.

jQuery(window).load(function(){
        jQuery('#myModal').modal('show');

    });
Martijn Pieters
  • 1,048,767
  • 296
  • 4,058
  • 3,343
Sakib
  • 126
  • 20
  • You could have also type in **google** : `load content 5 second later` But it's kinda difficult if you write **letter**.. – Dash Apr 21 '17 at 13:05
  • Please read [Under what circumstances may I add “urgent” or other similar phrases to my question, in order to obtain faster answers?](https://meta.stackoverflow.com/q/326569) - the summary is that this is not an ideal way to address volunteers, and is probably counterproductive to obtaining answers. Please refrain from adding this to your questions. – halfer Apr 23 '17 at 19:11
  • Flagged for moderator attention: your begging message has been removed once already, and your client's urgency is not our problem. Furthermore, no-one is entitled to priority treatment here, and it is impolite to ask - your question is not more important than anyone else's. If you need a speedy, guaranteed response then consider paying for help on another site (e.g. TopTal or AirPair). – halfer Apr 23 '17 at 19:13

1 Answers1

3

Use setTimeout to add a delay to a function/action.

jQuery(window).load(function(){
    setTimeout(function() {
        jQuery('#myModal').modal('show');
    }, 5000);
});
Blue
  • 22,608
  • 7
  • 62
  • 92