127
rated 0 times
[
133]
[
6]
/ answers: 1 / hits: 24685
/ 9 Years ago, thu, november 19, 2015, 12:00:00
I have a simple HTML file in which I want to display Bootstrap modal popup. Below is the code for this.
.js file:
<meta name=viewport content=width=device-width, initial-scale=1>
<link rel=stylesheet href=/po_ritesh/css/bootstrap.min.css>
<script type=text/javascript src=//code.jquery.com/jquery-1.11.3.min.js></script>
<script type=text/javascript src=https://cdn.datatables.net/1.10.9/js/dataTables.bootstrap.min.js></script>
<script type=text/javascript src=https://cdn.datatables.net/1.10.9/js/jquery.dataTables.min.js></script>
<link rel=stylesheet type=text/css href=//maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css>
<link rel=stylesheet type=text/css href=https://cdn.datatables.net/1.10.9/css/dataTables.bootstrap.min.css>
<link rel=stylesheet type=text/css href=./css/home.css>
<script src=./js/global.js></script>
<script src=./js/home.js></script>
button control:
<button class=myBtn type=button data-toggle=modal data-target=#myModal>test </button>
modal div:
<div class=modal fade id=myModal tabindex=-1 role=dialog aria-labelledby=myModalLabel>
<div class=modal-dialog role=document>
<div class=modal-content>
<div class=modal-header>
<button type=button class=close data-dismiss=modal aria-label=Close><span aria-hidden=true>×</span></button>
<h4 class=modal-title id=myModalLabel>Modal title</h4>
</div>
<div class=modal-body>
test
</div>
<div class=modal-footer>
<button type=button class=btn btn-default data-dismiss=modal>Close</button>
<button type=button class=btn btn-primary>Save changes</button>
</div>
</div>
</div>
</div>
More From » jquery