s9e Media Sites

s9e Media Sites 2.18.9

No permission to download
@JoshyPHP I've had some users reporting that youtube embeds are failing with a "Video Unavailable; Watch on YouTube". Adding referrerpolicy="strict-origin-when-cross-origin" to the generated generated <iframe> apparently fixes it.
 
@JoshyPHP I've had some users reporting that youtube embeds are failing with a "Video Unavailable; Watch on YouTube". Adding referrerpolicy="strict-origin-when-cross-origin" to the generated generated <iframe> apparently fixes it.

Maybe cloudflare related. Cloudflare make something with these referrer headers. I don't remember the rule but I fixed it by turning off a setting in Cloudflare.
 
@JoshyPHP I've had some users reporting that youtube embeds are failing with a "Video Unavailable; Watch on YouTube". Adding referrerpolicy="strict-origin-when-cross-origin" to the generated generated <iframe> apparently fixes it.
Interesting, do you have the URL of a video that reliably does that? There is some chicanery going on with referrers and YouTube. IIRC, removing referrers completely disables some other videos from being embedded. Mostly music videos from big copyright holders, as I recall.
 
Twitter/X embeds suddenly don't have the account username populating in the embed, it's just blank. Does anyone know if there's an easy fix for that?
 
so desktop is showing embedded tweets fine. account data is missing on mobile browser. though i have seen it happen on desktop browser now and then. and as expected this seems like an issue at twitter's end. you can try on this link which uses official twitter embed code.

 
so desktop is showing embedded tweets fine. account data is missing on mobile browser. though i have seen it happen on desktop browser now and then. and as expected this seems like an issue at twitter's end. you can try on this link which uses official twitter embed code.

Interesting, mine is actually the opposite, they show on mobile but are blank on desktop. Good to know that it is an issue on Twitter's end. Thank you!
 
Any chance you can revisit Truth Social? I tried a couple solutions that were mentioned but still doesn't seem to work.
 
Hi Joshy, apologies for disturbing.

I am trying to embed Rumble's URLs but I get an error.1755792101996.webp

An example is this video: https://rumble.com/v6wqpyi-thats-how-you-make-a-carbonara-mealswithmax.html?e9s=src_v1_s,src_v1_s_m (it's a funny and positive one, so don't worry :D ) Either the full URL, or with just the ID, I get the same error.

You mentioned that it may be that Rumble is not serving data (I believe to the server?), but I have no logs on the server (nothing shows up in Xenforo, nor on the errors.log file).

Any idea how I can troubleshoot?
 
Twitter/X embeds suddenly don't have the account username populating in the embed, it's just blank. Does anyone know if there's an easy fix for that?
What do you mean by no username? Can you give me an example of the URL you use and the BBCode it generates?

so desktop is showing embedded tweets fine. account data is missing on mobile browser. though i have seen it happen on desktop browser now and then. [...]
That sounds like an issue in Twitter's UI. In that case there's nothing we can really do unless there's an alternative provider for tweets. I don't have great hopes for that though.

Any chance you can revisit Truth Social? I tried a couple solutions that were mentioned but still doesn't seem to work.
I would consider making a separate add-on for it, but it's very difficult for me at the moment to spend time on new projects. If you're interested in sponsoring it by paying for the development cost, you can send me a direct message and I'll reply asap. (it's faster if you can give me a budget range)

You mentioned that it may be that Rumble is not serving data (I believe to the server?), but I have no logs on the server (nothing shows up in Xenforo, nor on the errors.log file).

Any idea how I can troubleshoot?
You can try "unfurling" the URL in the Test URL unfurling tool in your admin panel. If Rumble refuses to communicate with your server, the unfurl tool will not work. If the unfurl tool works but this add-on doesn't, it may be fixable on my end.

Either way, you should be able to embed Rumble videos if you open the video page in your browser, click on <> Embed then you use the URL in Embed IFRAME URL to post in XenForo.

Is there a way to get AP News short video links to embed as a video?
What Chromaniac said, it doesn't look like they offer a way to embed their content.
 
You can try "unfurling" the URL in the Test URL unfurling tool in your admin panel. If Rumble refuses to communicate with your server, the unfurl tool will not work. If the unfurl tool works but this add-on doesn't, it may be fixable on my end.

Either way, you should be able to embed Rumble videos if you open the video page in your browser, click on <> Embed then you use the URL in Embed IFRAME URL to post in XenForo.

I get this error:
1757491806530.webp

Tried another URL (gotten from the main page of rumble), same error: 1757491955467.webp

The embedded URL gives me this, But I am playing the video as I write:
1757492007467.webp

EDIT: Just a little note. I am building a CMS site in PHP, and in that case the Rumble link is correctly being managed by Embera.
 
Last edited:
I'm surprised by how this plugin works. This is currently basically hotlinking s9e.github.io for each embed, which gives tremendous power to whoever controls that github repo, who can instantly change the behaviour of embeds worldwide on all websites using this plugin (phpbb & xenforo). This is also preventing you from using any kind of meaningful CSP on your server.
Clearly the author is a reputable plugin author, but nobody is protected from having their credentials stolen (see the recent npm problems).

If you're concerned about security I would strongly advise to git-clone https://github.com/s9e/s9e.github.io , and run your own little copy of the /iframe/ directory by editing the different templates, for example _media_site_embed_twitter (you replace calls to github with local calls)
Maybe take the opportunity to have a look at the code of those embeds.

It would be a good suggestion/improvement, imho, the have a copy of the iframe directory saved locally (in /js, in /styles, in an external webserver you control,etc) and have the option to use those instead of the cloud ones (basically ; have a variable for setting where the embeds are hosted).
 
Last edited:
I would strongly advise to git-clone https://github.com/s9e/s9e.github.io , and run your own little copy of the /iframe/ directory by editing the different templates,

It is in the FAQ

Q: What is https://s9e.github.io and how is it used?
A: It has become a popular pattern among social websites such as Facebook and Twitter to provide embeddable content not in the form of an iframe but as a JavaScript executable. There are several issues with this approach; Firstly, some of them only work during the initial page load and not in the post's preview. Secondly, it gives the third party content providers complete control over the current page. To sidestep those issues, this add-on uses a separate iframe that acts as a sandbox to isolate your website from those third parties. This iframe is hosted on GitHub as a small (~1 KB) static HTML file. You can view an example of it on this page. The details of the embeddable content (such as the tweet's ID) are stored in the fragment part of the address, meaning that it is not sent to the GitHub server.
 
The embedded URL gives me this, But I am playing the video as I write:
View attachment 326838
Your screenshot shows that you pasted the URL in the admin panel, I was talking about posting the embed URL directly within a post. Those should work without connecting to Rumble.

It would be a good suggestion/improvement, imho, the have a copy of the iframe directory saved locally (in /js, in /styles, in an external webserver you control,etc) and have the option to use those instead of the cloud ones (basically ; have a variable for setting where the embeds are hosted).
I would consider making the root URL configurable if I thought people would use it, but I'm more concerned it would create more issues than it solves. If you want to use your own URLs I recommend doing it using template modifications rather than template replacements. That's how I recommend modifying one's board whenever possible.

Wrt hosting your own copy of the iframes, I strongly caution against doing so on forum's domain. That's one of the reasons why the add-on doesn't serve those pages. As mentioned in the FAQ that @Digital Doctor posted, some iframes need to embed the content provider's (e.g $social_network) own script. If you run the iframe on the same origin then you're in a worse position in terms of security because the iframe and whichever JavaScript it embeds will be allowed to interact with the parent's content. (if I remember the security model correctly) That's not a problem if you have a separate domain for static assets, but I feel that people who spend that much time on configuration would rather disable Twitter altogether.
 
I've had a few members report over the last couple of weeks that videos that are embedded are no longer playable within the forum. The play triangle is missing, clicking on the video either does nothing in the example of YouTube or opens the associated social media site in a new tab for X or Instagram.

I'me not experiencing the issue myself. Currently running 2.18.9 on the latest version of XenForo.
 
Back
Top Bottom