javascript - Foundation 5 reveal won't open (Appended to BODY with jQuery) -
I'm searching SO SO for a reply to my issue, but nothing could be found.
I have added a manifest model to the body with Jack. Now when I click on the button which opens the modal, only the overlay is shown. I can not understand what the problem is.
I made an example on Codepane.
"Open Model 1" programmaticly attached models should be opened. Opens the "Open Model 2" modal, which is placed directly in the body. (It just shows that it usually works)
Maybe one of you guys can help me with it.
Thank you very much.
EDIT: This error has been displayed in firebug:
Type error: settings are not defined. Show (modal, settings.css.open);
You have to call the foundation by adding model material divas
$ (Document) .ready (function () {$ ("body") .append ('& lt; div class = "reveal-manifest small foo1" data-reveal »gt; & lt; p & gt; test & Lt; / p & gt; & lt; / div & gt; '); $ (document). Foundation (); $ (document) .on (' click ',' .trigger_foo1 ', function (e) {e .preventDefault (); $ (".foo1"). Foundations ('open', 'open');}); $ (document). ('Click', '. Trigger_foo2', function (e) {e. PreventDefault (); $ (".foo2"). Foundations ('open', 'open');});});
Comments
Post a Comment