BudBrain Posted September 28, 2016 Share Posted September 28, 2016 Hi, I'm just starting out with Phaser, and the project I'm working on requires a Json file to be loaded. Can anyone tell me why the official Phaser Json example doesn't work? I have tried replicating this on my own server and that doesn't work either. Thanks Link to comment Share on other sites More sharing options...
rich Posted September 28, 2016 Share Posted September 28, 2016 Ah it's just because the json file on our server hasn't got CORS set-up at the moment. Swap the URL for another one. Any one, and it'll work fine, as long as the server has been set-up for CORs. Link to comment Share on other sites More sharing options...
BudBrain Posted September 28, 2016 Author Share Posted September 28, 2016 Thanks, seems the reason it wasn't working on my side is because I'm using Phaser within the .NET framework and needed to allow the download of json file mime type in the web.config. <staticContent> <mimeMap fileExtension=".json" mimeType="application/json" /> </staticContent> (Added to the <system.webServer> section) Link to comment Share on other sites More sharing options...
Recommended Posts