-
Notifications
You must be signed in to change notification settings - Fork 347
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
In WP v4.7 REST API posts?filter[category_name]= does not work! #308
Comments
Same problem on a live app here. |
Reverting to 4.6.1 as directed above fixed the problem. But obviously this is a short-term fix. Does the latest beta fix this? |
nope, we need to evolve to handle those breaking changes. Please do not upgrade until this is resolved. |
I will not have time off until beginning of January. Just be patient for this. PR are welcome :) |
If I find time, maybe I'll try solving this. config.cson:"api": Or alternatively, it can be deduced from the baseUrl. |
Does it imply to create a WP plugin? |
No. If I understand correctly, WP API 1 was integrated to it (not version 2, which we use). |
ok, is it two different endpoints? |
it seems |
you can select the Rest api you want using |
WP-API being integrated to the core is really great, we wont need to install a plugin anymore. Will make the necessary changes and update the Docs ASAP (most probably first week of january) |
Awesome I'm not sure I understand what an endpoint is. |
Thanks! |
wp-json/wp/v2/posts?filter[category_name]=cat still doesn't work. Did it change? |
@bigbassroller
|
yes please update your WP to 4.7 or higher |
@bigbassroller Since WP 4.7, filter has been removed from WP-API |
added default config.cson (cherry picked from commit 3a1eab2) committing default config.xml (cherry picked from commit 634daf3) config.xml that works add hebrew change preferred language to hebrew add icon and splash-screen ignore DS_Store files - they belong to CrashPlan i think. On my new Mac Adding siksik to the list :) Update zh.cson Add four words:ru、tr、enabled、pushNotifications,fix three words! Resolving issue wordpress-clients#221 Resolving issue wordpress-clients#221 bump beta09 hebrew working, changed menu, overide some templates, added files to repository changed .gitignore, which might be a mistake, and i'll look into that clean up menue, posts seem to work fine, still need to set order Adding missing !default Adding Trou Idees TI app Update AbstractItemService.js Update AbstractListService.js Add the taxonomy term to the cache same modification to file AbstractItemService.js adding the way to update the font Adding some more ios apps! another great app! upgrade to android API-23 keeping an iOS implementation of notif count for reference update crosswalk bump added keystore vidoes are now pressented in post list, so there is no need to open post. Ive tried narrowing the "access" and "allow-navigation urls, but then the videos didnt play. need to play with this more." push notification and package change Update AbstractItem.js The post is not refreshed after a pull to refresh Below is the modification in line 22 to clear the cache : this.service.clearCache(); Changed the dutch translations, removed a typo and added new strings! Adding another great app: CommonTales Two new apps! adding missing command new iOS app update Prerequisites versions new android app preparing beta11 use templates for author/authors views fix wordpress-clients#59 encoding problem Fetching categorie/tag/custom names from post list to update page title remove native transitions ios 10 ready fix wordpress-clients#59 encoding problem in my posts-list.html support orderby menu_order order posts by menu_order, when choosing category upped the version for fixing post order issue when choosing category overriding categories list template, to add image to each category category images New embedded path. Closes wordpress-clients#279 Author -> Autor Author is in German: Autor Plural: Autors -> Autoren adding docs for a new issue wordpress-clients#278 Custom Menu Logo Cleanup Prep for dist Update config.default.cson Logo Image in /config/logo.png forgot default adding manifest for progressive web apps adding serviceWorker support. Disabled by default service workers docs remove share button when on browser bump beta13 use https version of my web service Fix Pagination on customPosts. Closes wordpress-clients#283 Update Build,md Typo error Update Dutch Translations While using the app I noticed some translations were not in context or inline with WordPress translations. Changed those! custom post and custom taxo queries are customizale through the conf. Closes wordpress-clients#288 add a scss variable for the menu bar title with icon bump beta 14 migrate to yarn Removes ES6 code that needs a polyfill bump beta15 due to a critical bug... Replace baseUrl http:// with https:// Fix this error on first start : ```XMLHttpRequest cannot load https://dev.julienrenaux.fr/wp-json/... The 'Access-Control-Allow-Origin' header has a value 'http://null' that is not equal to the supplied origin. Origin 'null' is therefore not allowed access.``` Update Build.md Typo error add new iOS app upgrade cordova-ios and cordova-android add more logs for admobs upgrade crosswalk bump beta16 Update AbstractItem.js The post is not refreshed after a pull to refresh Below is the modification in line 22 to clear the cache : this.service.clearCache(); Changed the dutch translations, removed a typo and added new strings! Adding another great app: CommonTales Two new apps! adding missing command new iOS app update Prerequisites versions new android app preparing beta11 use templates for author/authors views fix wordpress-clients#59 encoding problem Fetching categorie/tag/custom names from post list to update page title remove native transitions ios 10 ready New embedded path. Closes wordpress-clients#279 Author -> Autor Author is in German: Autor Plural: Autors -> Autoren adding docs for a new issue wordpress-clients#278 Custom Menu Logo Cleanup Prep for dist Update config.default.cson Logo Image in /config/logo.png forgot default adding manifest for progressive web apps adding serviceWorker support. Disabled by default service workers docs remove share button when on browser bump beta13 use https version of my web service Fix Pagination on customPosts. Closes wordpress-clients#283 Update Build,md Typo error Update Dutch Translations While using the app I noticed some translations were not in context or inline with WordPress translations. Changed those! custom post and custom taxo queries are customizale through the conf. Closes wordpress-clients#288 add a scss variable for the menu bar title with icon bump beta 14 migrate to yarn Removes ES6 code that needs a polyfill bump beta15 due to a critical bug... Replace baseUrl http:// with https:// Fix this error on first start : ```XMLHttpRequest cannot load https://dev.julienrenaux.fr/wp-json/... The 'Access-Control-Allow-Origin' header has a value 'http://null' that is not equal to the supplied origin. Origin 'null' is therefore not allowed access.``` Update Build.md Typo error add new iOS app upgrade cordova-ios and cordova-android add more logs for admobs upgrade crosswalk bump beta16 bump 2.0.0 Adding docs about how to use crosswalk lite adding accordion! forgot to mention crosswalk version update prerequisites Fix typo showing MD file on Github Fix typo on Google Fix typos on BUILD.md Fix Debug command Update pt translation new app Open links in a comment in Safari Links in a comment open in app and not in Safari / default Browser. Adding prepLink to commentCtrl.comment.content.rendered fix this issue. update cordovaPlugins version i tested these newest Plugins on Android and IOS, all is right! WordPress 4.7 ready. Closes wordpress-clients#308 bump 2.0.0 wp 4.7 ready tmp before rebase with upstream fix error css about wp-caption now image in post can show center! Update CHANGELOG.md Update CHANGELOG.md update dependencies,tested it! now no “Can't run npm run restore” questions,byebye ionic.project! rollback cordova plugin upgrade (until fixed) bump 2.0.1 rebased to comply with wp 4.7
I have installed WPHC v2.0.0-beta16 on Linux. The installation is OK, requests to dev.julienrenaux.fr/wp-json working OK, but I found some problem on my own WP server side. I have installed new WP 4.7 + WP Rest API. But categories, search, tags filtering does not work - each time all posts are shown. This is critical.
I found an article: https://jeremy.hu/update-rest-api-post-embeds/ - it tells that in WP 4.7 filter will NOT work:
wp-json/wp/v2/posts?filter[category_name]=wordpress
Now need to be:
wp-json/wp/v2/posts?categories=11
and need to retrieve by ID, not slug.
I have downgrade WP (with help of plugin WP Downgrade) from 4.7 to 4.6.1 - this fixed this issue. Now wp-json/wp/v2/posts?filter[category_name]= works OK!
But are there other solutions? Plugins for WP? Or need to make core update to WPHC to use new API techniques?
The text was updated successfully, but these errors were encountered: