[wp-hackers] Checking for a duplicated post while using XML-RPC WordPress API

Marko Heijnen mailing at markoheijnen.nl
Thu Sep 20 08:56:35 UTC 2012


Het Alex,

There is no good way to do it currently except when you write your own XML-RPC method.
When inserting date through the XML-RPC the client needs to deal with this. That is to only good way of doing this.

This can't really be handled by the database structure because there isn't a default way of saying what is duplicated and what is not.

Marko

Op 18 sep. 2012, om 17:04 heeft Alex Rayan <alexrayan69 at gmail.com> het volgende geschreven:

> Hello everyone,
> 
> I'm trying to come up with the solution to check for a duplicated post
> entry through XML-RPC WP API (
> http://codex.wordpress.org/XML-RPC_WordPress_API/Posts#wp.newPost )
> 
> I use it to insert posts in the blog automatically while getting the
> external content from the feeds or other databases. The problem is there
> seem to be no easy or elegant way to check for a duplicated entry unless I
> first get all the posts and check for a duplicated title / description /
> meta key.
> 
> I was wondering if anyone came up with a more robust solution to do it.
> The ideal way would be to have it handled by the database structure
> checking for duplicated entries. It seems it was never an issue since
> Wordpress is originally meant for manual entries of each post.
> 
> Any suggestions would be appreciated.
> 
> Regards,
> Alex
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers



More information about the wp-hackers mailing list