On Friday, November 11, 2016 at 1:15:58 PM UTC-5, Mike Stephenson wrote:
>
> Yeah exactly that doesn't work. How do I avoid that error? It says:" 
> XMLHttpRequest cannot load 
> https://biglibrary.pythonanywhere.com/app/phonegap/temp.json. No 
> 'Access-Control-Allow-Origin' header is present on the requested resource. 
> Origin 'null' is therefore not allowed access." when I use your code 
> snippet.
>

In the future, please explain in more detail what you are trying to do and 
show any code you have tried along with any error messages.

Note, browsers will not allow you to make Ajax requests to other domains 
(i.e., cross-origin requests) unless CORS has been set up with those 
servers (do some research on CORS).

An alternative is to make an Ajax request to *your own server*, and have 
your server then make the request for the resource in question and simply 
pass it back to the browser.

Anthony

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to