I have configured devserver proxy with my staging server url of my site, and made axios request using client server url. But the ajax request is returning just a html file, no response getting from server.
Access-Control-Allow-Origin: *
Access-Control-Allow-Methods: POST, GET, DELETE, PUT, PATCH, OPTIONS
Access-Control-Allow-Headers: token, Content-Type
Axios({
method: 'get',
url: 'http://10.1.3.159/v3/se/oauth/getAccessToken.php',
data: {}
}).then(function (response) {
console.log(response);
});
module.exports = {
devServer: {
proxy: 'server url'
}
}
These also added in php file headerxhr response
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire