Enable CORS on JSON API Wordpress

前端 未结 10 2110
南笙
南笙 2020-12-03 03:28

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

10条回答
  •  臣服心动
    2020-12-03 03:51

    Ok I finally figured out an easy way...

    You just have to add:

         
    

    On the file api.php, this file is located in wp-content/plugins/json-api/singletons/api.php

    I hope it helps more people with the same problem!

提交回复
热议问题