Path: csiph.com!eternal-september.org!feeder.eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail From: Ben Bacarisse Newsgroups: comp.lang.javascript Subject: Re: video and cross origin Date: Fri, 13 Jul 2018 12:10:57 +0100 Organization: A noiseless patient Spider Lines: 33 Message-ID: <87tvp3o0fy.fsf@bsb.me.uk> References: Mime-Version: 1.0 Content-Type: text/plain Injection-Info: reader02.eternal-september.org; posting-host="48eb471516f8e1ca1cf291db7eb9b491"; logging-data="6761"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/ffeCYHwvjd93gYGkZTkdkQ/oh2XtoY2I=" Cancel-Lock: sha1:DXv/Q02l0uvWytmrAmsT5cRw/Ho= sha1:gE413Yk+ZPgVNHE5V3qrZmCE2dA= X-BSB-Auth: 1.2bdeaca192568c161cc8.20180713121057BST.87tvp3o0fy.fsf@bsb.me.uk Xref: csiph.com comp.lang.javascript:35423 "Evertjan." writes: > Andrew Poulos wrote on 13 Jul 2018 in > comp.lang.javascript: > >> On 13/07/2018 12:59 PM, Andrew Poulos wrote: >>> While testing locally I found that if the HTML contains a video element >>> then the video plays as expected in Chrome. Yet if I dynamically >>> recreate the same video element Chrome complains that >>> >>> "Cross origin requests are only supported for protocol schemes: http, >>> data, chrome, chrome-extension, https." > > This clearly states what you are asking. > > Do you see "file" as one of the supported schemes? I think there's some miscommunication here. Andrew is asking why the request is considered to be "cross origin" in the first place. In other words, why does the question of whether this is a supported instance of such a thing even come up? That's a reasonable reading of the error message. Howver, I suspect you are right, and the error message is supposed to answer the question, but the way it is worded does not do that. Maybe the message is supposed to mean something like "Origin checks are only supported for protocol schemes http, data, chrome, chrome-extension and https. All others will be taken to be invalid cross-origin requests." -- Ben.