shypike wrote:I still don't understand what this is about.
Can you explain in layman's terms why this is useful?
I actually can't claim to fully understand the sense of these headers. As far as I understand it should a browser only do cross-site Ajax request when it has the explicit permission of the web server. Either a general permission that applies to all hosts (as the sources of the JS-code that do the requests) or only for certain hosts. And that applies to certan kinds of requests. For example:
Code: Select all
Access-Control-Allow-Origin: *
Access-Control-Allow-Methods: POST, GET, OPTIONS
means: allow all hosts to do POST-, GET-, and OPTIONS-requests.
Current Firefox obviuosly does everything we want but says afterwards 'Oh Honey! This was not right!' (Or is it just jQuery that is a little prudish? - I don't know.) But we probably have to expect that future browsers will be more sensitive with these things...
Excuse me, in layman's terms for what this is useful: When we currently feed sabnzbd with nzbs from pertinent websites they have to be saved locally an then get uploaded to (or locally loaded from) sabnzbd. By Ajax-requests we can do this with one click from every site that offers nzb-files.
I will try to send you a pull request tomorrow. My git-, github- , and Python-skills are not really famous but maybe my code is not too terrible though. Sorry, I have to come to an end for today, regards, T.