最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

json API plugin not returning any post with get_category_posts

programmeradmin2浏览0评论

I am using the json api for the api calls in my WordPress site. When I tried

;slug=catname

Then the default post category news can not be obtained.

And The response is: {"status":"error","error":"Not found."}

Do anybody have idea, what's wrong with this?

I am using the json api for the api calls in my WordPress site. When I tried

http://example/api/get_category_posts&slug=catname

Then the default post category news can not be obtained.

And The response is: {"status":"error","error":"Not found."}

Do anybody have idea, what's wrong with this?

Share Improve this question edited Oct 4, 2016 at 9:33 Naresh Kumar P 3671 silver badge6 bronze badges asked Oct 3, 2016 at 20:35 Ionic DevIonic Dev 32 bronze badges 1
  • Please post some complete code so we can debug it maybe – Ahmed Fouad Commented Oct 3, 2016 at 22:00
Add a comment  | 

1 Answer 1

Reset to default 0

Have you tried setting post_type to see if that fixes it?

I know documentation doesn't say it's required, but in the past I was only able to get it to work by passing the post type

https://wordpress/plugins/json-api/other_notes/

发布评论

评论列表(0)

  1. 暂无评论