How to get all posts (in chunks) via XML-RPC?

According to topic in official forums [xmlrpc] How to get posts with offset? The existing XML-RPC APIs don’t really provide a way for collecting all of the post data right now. (Joseph Scott) Topic is somewhat old and I am not aware if there were some changes since, but from quick look at source it … Read more

Connect external web app to wordpress

There’s the XML RPC – the Remote Posting Protocol – that is already in use by WP.org Applications. What you’re searching for is wp.newPost. The API is extensible. The URL for the XML RPC is http://example.com/xmlrpc.php To send data to WP, use xmlrpc_encode_request() where the first argument would be wp.newPost and second one your arguments … Read more

Authentication/API Questions

Why don’t you write a quick plugin … called “is user logged in” that registers a URL call. So the user hits the page, then the Flash or Java could just hit: http://mysite.com/customurl?hash=wordpress_logged_in_[hash] Then the plugin would run and return true or false. References: http://codex.wordpress.org/WordPress_Cookies#WP_.3E_3 This way you keep everything within reach of the WordPress … Read more

Sync posts from one WordPress site to another

Have you tried codex.wordpress.org/XML-RPC_Support. This code works, in conjunction with the IXR library found at incutio: include(‘IXR_Library.php’); $usr=”theusername”; $pwd = ‘thepassword’; $xmlrpc=”http://not-therealurl.com/xmlrpc.php”; $client = new IXR_Client($xmlrpc); $client -> debug = true; //optional but useful $params = array( ‘post_type’ => ‘post’, ‘post_status’ => ‘draft’, ‘post_title’ => ‘Test Post’, ‘post_author’ => 4, ‘post_excerpt’ => ‘This is my … Read more

WordPress.org Support Forum API

That´s no big deal if you got the RSS feed, have a look at it. There is a pubDate which you can use to check for the age of the topic. strtotime() or anything alike will help you to check if that´s older than 30 days. And you also got a link-element. This leads you … Read more

get WP-API by page id

If you want to use v2 of the API (which is the current one you should be using), the endpoint is mysite.me/wp-json/wp/v2/pages/1234 where 1234 is the page ID. https://developer.wordpress.org/rest-api/reference/pages/#retrieve-a-page

Gutenberg internal page link search box

I found a solution and thought to post it here as others might need it el(URLInput, { className: props.className, value: attributes.linkURL, placeholder: i18n.__(‘Set the specific url’), onChange: function( url ) { props.setAttributes({ linkURL: url }); } }) Does exactly what I need.

WP API : date_query parameter

As of WP >= 4.7 filter[] is not supported and have been removed. Also WP REST API Plugin became part of WordPress Core. According docs your link should be: https://wptest.enguerranweiss.com/wp-json/wp/v2/posts?orderby=date&order=desc&after=2016-10-13T17:00:00 EDIT As enguerranws mentioned the date should be in ISO8601 format

How to get the attached gallery in the rest API?

To my knowledge this can’t be done out of the box. So you could make use of what get_post_galleries() or get_post_gallery(), the latter is just making use of the former, are doing by adding an endpoint. A minimal example could look like shown below. function rest_get_post_gallery( $data ) { //set FALSE for data output $gallery … Read more