Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialRobert Myers
Courses Plus Student 61 Pointsphaser.js wont open error security error
When i click on phaser.js in workspace it says connection lost then error opening file
2 Answers
Dave McFarland
Treehouse TeacherHi Robert,
You can get that error if you downloaded the files to your computer, and tried to open the index.html file in a browser. Many browsers limit how JavaScript interacts with your local file system, and loading files the way Phaser.js, will trigger an error, unless you view the web page from a web server. If you use workspaces to edit and view the files you won't get that error.
Another option is to load a simple web server on your computer and view the game page that way. A really simple way, if you use the Chrome browser, is to use the Web Server for Chrome extension. Just follow the instructions on the page -- https://chrome.google.com/webstore/detail/web-server-for-chrome/ofhbbkphhbklhfoeikjpcbhemlocgigb?hl=en -- and you'll be able to view the game just fine.
Daylin Jones
5,981 PointsThis was a BIG help. Thanks!
B G
1,866 PointsB G
1,866 PointsAll other files open in the Work space but not phaser.js. Iam not trying to download anything just trying to open it in the Work space like I would any other file. Tried on Firefox and Google Chrome. It is not opening.