Closed mistermendez closed 8 years ago
How are you using Showtimes? Through Browserify, or running on a server?
I also get this error, using a local server from browserify
@labago I don't have any experience running Browserify, you mind sharing the code you have with instructions on how to run it?
I honestly can't describe that to you since i don't know much about it myself haha, I didn't set the project up. What I can tell you is that I successfully installed this module to the project, I require it just like any other module, it gets bundled into a batch js file with all the other modules and scripts on this local app. Then, when loaded in the browser and running the example code provided here https://www.npmjs.com/package/showtimes I get the 405 error.
Looking into this, it doesn't seem like Showtimes can be used within a Browserify environment because Google Movies doesn't allow cross-origin requests. If you do want to use it, you'll have to run Showtimes on a server, and have your frontend code call that.
Request to Google Movies returns -
Failed to load resource: the server responded with a status of 405 (Method Not Allowed)
XMLHttpRequest cannot load http://google.com/movies?hl=en&near=20001&date=0&start=0. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:4444' is therefore not allowed access. The response had HTTP status code 405.