Open kacinash opened 8 years ago
What do you mean by an Ajax window? You will probably have to re-call $.bigfoot
whenever new content is added that contains footnotes, regardless of how it is added (Ajax, manual DOM additions, etc).
You can see an example of the window here: just click on "Fort No 1" and the window will pop up. When I was styling the footnotes there with bigfoot, the java did not work--there was just floating text there. But if I went to the actual page that the ajax window is pulling the text from, bigfoot would work just fine. So something about the window and bigfoot was conflicting.
After the content is retrieved and the modal is added, do you run $.bigfoot()
again? It's hard to tell what that part of the JavaScript is doing.
I'm not sure what you mean by that. I have
<script type="text/javascript" src="./resources/bigfoot/bigfoot.js"></script>
<script type="text/javascript">
$.bigfoot();
...
in the footer of the page, but my guess is that it the window is not loading it for some reason.
This is likely a problem with whatever is loading the content via AJAX not running the scripts of the retrieved page when adding it to the DOM. If whatever does the AJAX provides a callback for when the content is added, you could manually call $.bigfoot()
.
I attempted to implement the footnotes on a page that is typically viewed as a popup jQuery ajax window, but it does not work. If I view the actual page, it works fine. Is there any work around to get it to function inside the ajax window?