Activate a modal without writing JavaScript. SetTherefore, initially, this is what I had:data-toggle="modal"
on a controller element, like a button, along with adata-target="#foo"
orhref="#foo"
to target a specific modal to toggle.
<a data-toggle="modal" href="#help-with-url" >Content not showing up?</a>
However, what I found was that on pages that are loaded via ajax which the contents are put on a separate dialog, one cannot use what they described above for reasons I do not know why. I checked to see if there were any errors in the bootstrap js, but couldn't find any. I did solve it by just calling the modal using the javascript way, like so:
<a onclick="$('#help-with-url').modal()" data-toggle="modal" >Content not showing up?</a>
No comments:
Post a Comment