Groups
Groups
Sign in
Groups
Groups
Ratchet
Conversations
About
Send feedback
Help
HOW TO CLOSE A MODAL USE JS
70 views
Skip to first unread message
WEB LOVER
unread,
Nov 19, 2015, 11:37:40 PM
11/19/15
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Ratchet
As the title describe how do i close the modal use js. The following is my code.
<a href="#myModalexample" class="btn">Open modal</a>
<div id="myModalexample" class="modal">
<header class="bar bar-nav">
<a class="icon icon-close pull-right" href="#myModalexample"></a>
<h1 class="title">Modal</h1>
</header>
<div class="content">
<p class="content-padded">The contents </p>
</div>
</div>
WEB LOVER
unread,
Nov 19, 2015, 11:52:50 PM
11/19/15
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Ratchet
【solved】the modal is launched by class "active", so we can remove the "active" class to close the modal:
$("#myModalexample").removeClass("active");
在 2015年11月20日星期五 UTC+8下午12:37:40,WEB LOVER写道:
Reply all
Reply to author
Forward
0 new messages