I am new to AngularJs. I am trying to use the ng-include directive in the index.html file to include a header template. In my local, I run it offline, and not on any web server. On the index page, the header file loads fine on Firefox, but on Chrome. I get the error "Cross-start requests are only supported for HTTP."
Next, several logs from the error stack are added:
The resource is interpreted as Script, but is passed with the MIME type text / html: "file: ///Users/pradeep/Angular_demo/header.html". index.html: 305 XMLHttpRequest cannot load the file: ///Users/pradeep/Angular_demo/header.html.
Cross-start requests are only supported for HTTP. angular.js: 8109 (anonymous function) angular.js: 8109 sendReq
Please help me solve this problem in Chrome so that I can run it as a standalone application.
Regards, Pradeep
source
share