- 🇫🇮Finland anaconda777
Hi,
Facing the same problem.
Basically, it is easy to reproduce like this with NG lightbox module for example.Prerequisites
1. List H5P content using views
2. Configure NG lightbox to open H5P content to a modal window (core modal)repeat the problem:
1. Click a H5P link which opens H5P content to a modal = All is working
2. Close the modal
3. Click again, any H5P link which opens it to a modal. = H5P content does not load, the other fields of that page is visible. - 🇺🇸United States illeace
I can confirm that this still happens in 2.0.0-alpha5. Here's some sample markup to add to a body field with Full HTML enabled:
<p> Click the links below. </p> <p> <a class="use-ajax" href="/node/16" data-dialog-type="modal">Basic Page</a> </p> <p> <a class="use-ajax" href="/node/9" data-dialog-type="modal">H5P Page</a> </p>
When clicking that first link (the basic page), I see the node content any time I click it. When I click the second (H5P link) I see the H5P the first time I click it. If I close the modal and click the link again, I see the page title and author info, but the H5P doesn't render. Further, when examining the JSON data that is returned from the AJAX callback, the first response includes 'add_css' and 'add_js' commands and the second click AJAX data does not include them. Further playing with this indicates that sometimes this is true for the first click -- no 'add_css' or 'add_js' commands and no rendered h5p, so it's not quite as simple as the first time always works.