Hi all,
I am using a modal in Bootstrap 4 to show remote content from different HTML files.
For this purpose I found some JS on stackoverflow:
Code:
<script>
$('body').on('click', '[data-toggle="modal"]', function(){
$($(this).data("target")+' .modal-body').load($(this).data("remote"));
});
</script>
This works fine with links in the main page - but I need to access those remote filled modals directly via the URL.
Example: I type something like index.php?id=remote.html#mymodal to open my site with an active modal filled by remote.html.
So I would need some piece of script that examines the incoming URL request for certain parameters and then open the modal with the requested remote content on pageload.
If someone can help me out, I'd be very happy!
Thanks a lot and best regards,
Alex