Tag Archives: json API
Ionic wordpress Access-Control-Allow-Origin json ApI error (CORS)
Posted by:Ryan zongo, May - 07 - 2016
What to do when your ionic cannot pull data from your wordpress with JSON ApI ?
This plugin provides a JSON format for the content that is in the wordpress. But
- You will need to go to wp-content/themes/myTheme
- open functions.php
- Add this header(“Access-Control-Allow-Origin: *”); right after <?php
<?php
header(“Access-Control-Allow-Origin: *”);
II. solution 2
Some advice to modify directly the pluggin
You just have to add:
<? header("Access-Control-Allow-Origin: *"); ?>
On the file api.php, this file is located in wp-content/plugins/json-api/singletons/api.php
Your choice.
Category
Recent news
Tags
Access-Control-Allow-Origin
angular wordpress
API_KEY_FOR_ANDROID
application android
application Burkina 24
burkina faso media
Business
Company
Creative
cretes
creteslab
Deploying Ionic
Ionic
Ionic error androidKey
ionic icon
ionic issue
ionic json
ionic resources
ionic splash
json API
simple
visual studio
whitelist
wordpress mobile
wp json