Reputation: 31
I know of wp-json
, but I cannot use it. I need to use ?rest_route
While this returns first 10 posts in any category
?rest_route=/wp/v2/posts
I would like to display specific category i.e 60
None of the combinations I tried work
ie. ?rest_route=/wp/v2/posts/?categories=60
Any ideas?
Upvotes: 3
Views: 1302
Reputation: 3799
Try with &
instead of ?
like this - http://www.example.com/?rest_route=/wp/v2/posts/&categories=60
.
You can also have multiple categories separated by comma like http://www.example.com/?rest_route=/wp/v2/posts/&categories=60,61
.
Upvotes: 4