lundi 30 mars 2015

HTTPS with $http in Angular not working

I'm building a Facebook Tab using Angular. I'm doing a $http request to a PHP page on the same domain. The request looks like this:



$http({
method: 'JSONP',
url: '/api?action=saveResult&points=' + state.points + '&callback=JSON_CALLBACK',
cache: false
});


The app is served with HTTPS but when I try to run the app in a Facebook tab I get the following mixed content error:



Mixed Content: The page at 'https://example.com' was loaded over HTTPS, but requested an insecure script 'http://ift.tt/1IDxQ2M'. This request has been blocked; the content must be served over HTTPS.



I have also tried putting the full URL with HTTPS in the $http method, but I still get the same error.


Aucun commentaire:

Enregistrer un commentaire