I have this wordpress site with a plugin called JSON API. This plugin provides a JSON format for the content that is in the wordpress. I was able to enable CORS on the wordp
In WordPress project go to following file and do like this:
In wp-includes/rest-api.php
change:
header( 'Access-Control-Allow-Origin: ' . $origin );
to:
header( 'Access-Control-Allow-Origin: *' );
In wp-includes/http.php
change:
header( 'Access-Control-Allow-Origin: ' . $origin );
to:
header( 'Access-Control-Allow-Origin: *' );