javascript - How to open data uk modal on page load -


i using data-uk-modal open modal box open perfect when click on button want open when page load, have tie following code

<button class="md-btn md-btn-success" data-uk-modal="{target:'#my_id'}">open dialogue</button>  <div class="uk-modal" id="my_id" >       <div class="uk-modal-dialog">         <div class="uk-modal-header">             custom content here         </div>     </div>  <div class="uk-modal-footer uk-text-right">     <button type="button" class="md-btn md-btn-flat uk-modal-close">close</button> </div>  </div> 

this js code

please tell me how can open diwlogure box on page load

give button id , trigger click on page load.

html

<button class="md-btn md-btn-success" id="openmodal" data-uk-modal="{target:'#my_id'}">open dialogue</button> 

jquery

$(document).ready(function(){     $('#openmodal').trigger('click'); }) 

Comments

Popular posts from this blog

c# - Binding a comma separated list to a List<int> in asp.net web api -

how to prompt save As Box in Excel Interlop c# MVC 4 -

xslt 1.0 - How to access or retrieve mets content of an item from another item? -