Add Sticky support for Posts #349

Closed
kraftbj opened this Issue Nov 24, 2013 · 4 comments

Comments

Projects
None yet
4 participants

kraftbj commented Nov 24, 2013

No option to set a post as Sticky via the app.

Contributor

roundhill commented Nov 24, 2013

Just a note that it looks like the API offers support for this with a 'sticky' boolean: http://codex.wordpress.org/XML-RPC_MetaWeblog_API. Should be fairly simple to add.

Contributor

soulseekah commented Dec 19, 2013

I found out that the documentation is wrong, _prepare_post is not called in the mw_getRecentPosts, thus sticky is not available in the response at all (edited the Codex entry to reflect this).

https://github.com/WordPress/WordPress/blob/master/wp-includes/class-wp-xmlrpc-server.php#L4745

This can only be accomplished if the call is switched to wp_getPosts instead:

https://github.com/WordPress/WordPress/blob/master/wp-includes/class-wp-xmlrpc-server.php#L1413

Or waiting for a fix in core (http://core.trac.wordpress.org/ticket/26679), which may take years to roll out. Other than this blocker, I have a working patch that's pretty much done if the switch to wp_getPosts is viable (several variable renames need to be done for this, mt_allow_comments vs comment_status for example). Thoughts?

Contributor

soulseekah commented Dec 19, 2013

See: soulseekah/WordPress-Android@bf9d036
This works with a patched XML-RPC server, but gives an overview of the scope of the patch.
Of course, moving to the wp_ API for everything is best at this point, which probably needs a separate issue.

Owner

bummytime commented Apr 4, 2015

Closing issue and migrating to new repo.

@bummytime bummytime closed this Apr 4, 2015

@bummytime bummytime referenced this issue in wordpress-mobile/WordPress-Editor-Android Apr 4, 2015

Open

Add Sticky support for Posts #88

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment