Skip to content

Instantly share code, notes, and snippets.

@tdhartwick
Created November 28, 2016 18:29
Show Gist options
  • Save tdhartwick/4fe0af4304620bb52bffa1b82d7ed788 to your computer and use it in GitHub Desktop.
Save tdhartwick/4fe0af4304620bb52bffa1b82d7ed788 to your computer and use it in GitHub Desktop.
This will automatically open your modal and re-instantiate a modal when clicking the "x".
// Opens your Modal
$('** My Modal Class **').foundation('open');
// Re-instantiates Modal
$('** My Modal Class **').on('closed.zf.reveal', function() {
setTimeout(function() {
$('** My Modal Class **').foundation('open');
}, 100);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment