Skip to content Skip to sidebar Skip to footer

File Protocol Ajax Request

I have made a project whose structure is like this When I run my index.html from firefox, it is working fine. But I open it with my chrome it is giving CORS error. Now my proble

Solution 1:

Embed the data directly into the JavaScript or HTML and read it from there.

The data isn't going to be changing based on user input or the contents of a database, so having it in a separate "http" resource doesn't bring huge benefits.

If you want to store the data in XML to make it easier to edit in your development environment, then write a build tool to bundle it up into an embedded format before distributing.

Post a Comment for "File Protocol Ajax Request"