Cannot open local file - Chrome: Not allowed to load local resource
Asked 07 September, 2021
Viewed 2.9K times
  • 55
Votes

Test browser: Version of Chrome: 52.0.2743.116

It is a simple javascript that is to open an image file from local like 'C:.jpg'

function run(){

   var URL = "file:///C:.jpg";

   window.open(URL, null);

}
run();

Here is my sample code. https://fiddle.jshell.net/q326vLya/3/

Please give me any suitable suggestions.

16 Answer