I have a lot of embedded videos in popups on my site. A few of them are from a site other than YouTube or Vimeo (NFB.ca), so I am using the “special embed” in the add menu. The videos play fine, but if you close the popup while the film is playing, the video keeps playing. You can’t see it or control it, but you can hear it. The only way to stop it is to open the popup again and stop the video. All the other videos stop playing automatically when you close the window. Any way to get around this?
I hope I am not asking too many questions. I am trying not to overdo it!
It’s not really a “problem.” In fact, if the video player integrated into Sparkle is designed to be stopped when the popup is closed, it is not the case for embeds. When a popup is closed, it is not actually closed, but only made invisible. This is a choice made by Sparkle to avoid having to reload the popup each time it’s opened.
I tried to find a simple solution to your issue but without success. So, I don’t have a magical solution to give you, but I can still offer you two workarounds:
As I suggested in your previous topic, you can download the videos and host them on your own server to use Sparkle’s player. But this might be time-consuming if you have many videos to include, especially since the site you mentioned has videos in .m3u8 format. It means you will have to convert them (e.g., to .mov or .mp4) for Sparkle’s player to recognize them. If you do this, also remember to attribute the source sites to avoid any issues.
Another approach would be to open the video in a new tab (still on your site) instead of using a popup. A button would allow closing this tab, so the visitor can resume their navigation where they left off. Doing this without the visitor leaving your site is possible, but you will need to create a new page for each video contained in an embed. Additionally, it might create some inconsistency on your site and could potentially confuse visitors if some videos open in a popup while others open in a new tab. But if you want to try this method, let me know, and I’ll tell you how to do it.
Thank you, this is very helpful. I do have copies of the three videos in question, but I do not have the right to post my own copies. I can only direct them to the NFB site or embed, which incorporates their branding. I will try opening in a new page, assuming that when you leave the page, the video will stop playing.
Okay I need a little guidance. I made a separate page for the film. Embedded the film in the page. Put an “X” that links back to the “all films” page, but when I go there the video is still playing. So do you have a magic fix so that the “X” will also stop the video? Thank you.
Clicking an X sends you back to the previous page in the same browser tab, and clicking on an X will returns you to the previous page. So you are saying it needs to be another page in a new tab or window in the browser? Then when you close it you are returned to the previous page? Not sure how to set that up.
You open the videos with popups, not in new windows, which is different. As I explained earlier, when a popup is closed, it is not truly hidden but only made invisible. The video continues to play even if it’s no longer visible, except when using Sparkle’s player as it was designed to work properly with popups.
To stop the video, it needs to open in a new tab so that the visitor can close the tab. You’ll have to create new pages for these videos. Instead of opening the videos in popups, they will open in a new tab.
I do not see how to make it go to a new tab or window. That does not seem to be an option when setting the link. I chose to go to a page on the website, which is a page where the video is embedded. That did not work, because when I clicked on a link I made to return to the films page, it still kept playing, even though no popup was involved.
Sorry, I’m not sure I fully understood everything. I don’t understand how, when leaving the video page, the video could still be playing. Redirecting visitors to another web page that only contains the video is a good solution. To open this page in a new tab, here’s how to do it: When choosing the destination page (on click), you have a checkbox below. In English, it should be “open in a new tab.” If you check it, the page will open in a new tab. The visitor can then close this tab to return to the main page of your site. By closing this tab, the video will stop playing.