I have been using this embedded credentials method to retrieve photos from IP Cameras. Now that Google Chrome update blocked this method, I got this error:
[Deprecation] Subresource requests whose URLs contain embedded credentials (e.g.
https://user:pass@host/
) are blocked. See https://www.chromestatus.com/feature/5669008342777856 for more details.
I tried another method, using JQuery Ajax with basic auth. But I am getting another error instead.
XMLHttpRequest cannot load example.com. Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://example.com' is therefore not allowed access. The response had HTTP status code 401.
I cannot do any changes to the Web Service in Ip camera to allow cross domain request.
Looks like I only have 1 option left, that is to retrieve the image from server side, and feed it to browser? But that will waste my server bandwidth.
Any more suggestion/idea?
Thanks.
https://stackoverflow.com/a/7190487/3548578 – Dheeresh Jul 25 '17 at 09:33