Title: Link 2 posts programmatically?
Last modified: August 22, 2016

---

# Link 2 posts programmatically?

 *  [equeffelec](https://wordpress.org/support/users/equeffelec/)
 * (@equeffelec)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/link-2-posts-programmatically/)
 * Thanks for this awesome plugin, I am glad I found it, it is non intrusive, non
   destructive, and it was easy to install and set up!
 * To my issue:
 * Because of how my permissions are sets, my translators cannot create a translation
   for an existing post. Instead, they create a new post in their language, and 
   I then handle the rest.
 * Today this means I have to copy/paste everything from their draft into a “new”
   translation.
    I think I could probably just run a quick sql query instead, to“
   connect” their draft as a translation of the original post. I assume I could 
   do that by altering the meta table. But I want to make sure I get things right.
   Can someone help?
 * Thanks in advance
 * [https://wordpress.org/plugins/bogo/](https://wordpress.org/plugins/bogo/)

Viewing 5 replies - 1 through 5 (of 5 total)

 *  Plugin Author [Takayuki Miyoshi](https://wordpress.org/support/users/takayukister/)
 * (@takayukister)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/link-2-posts-programmatically/#post-5922544)
 * Why not allow your translators to create translations directly? It should be 
   easier.
 *  Thread Starter [equeffelec](https://wordpress.org/support/users/equeffelec/)
 * (@equeffelec)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/link-2-posts-programmatically/#post-5922564)
 * I’m not sure what permissions I need to give them for that. They are contributors.
   I don’t want them to have the possibility to publish posts, or edit things that
   have already been published.
    As “contributors”, they don’t have access to the“
   translate this post into …” link
 *  Thread Starter [equeffelec](https://wordpress.org/support/users/equeffelec/)
 * (@equeffelec)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/link-2-posts-programmatically/#post-5922595)
 * Miyoshi san, can you confirm if the following is the only connection that I need
   to make happen?
 * update_post_meta( $post_id, ‘_original_post’, $original );
 * (assuming I already have the original post, and a draft of the translation, not
   linked to it yet)
 * OR do I need to also *remove* something from the meta table?
 *  Thread Starter [equeffelec](https://wordpress.org/support/users/equeffelec/)
 * (@equeffelec)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/link-2-posts-programmatically/#post-5922602)
 * so, in case somebody else needs this, this works to associate an existing translation
   draft (post_id) to an existing other post (original):
 * update postmeta set meta_value=[original] where meta_key=’_original_post’ AND
   meta_value='[post_id]]’;
 *  Plugin Author [Takayuki Miyoshi](https://wordpress.org/support/users/takayukister/)
 * (@takayukister)
 * [11 years, 2 months ago](https://wordpress.org/support/topic/link-2-posts-programmatically/#post-5922619)
 * Since contributors can edit posts, if they have the access right to a locale,
   they should be able to “Translate into (the locale)”. Check the profile pages
   for the users. Do they have Locale checkboxes ticked?

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Link 2 posts programmatically?’ is closed to new replies.

 * ![](https://ps.w.org/bogo/assets/icon-256x256.png?rev=1047282)
 * [Bogo](https://wordpress.org/plugins/bogo/)
 * [Support Threads](https://wordpress.org/support/plugin/bogo/)
 * [Active Topics](https://wordpress.org/support/plugin/bogo/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/bogo/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/bogo/reviews/)

 * 5 replies
 * 2 participants
 * Last reply from: [Takayuki Miyoshi](https://wordpress.org/support/users/takayukister/)
 * Last activity: [11 years, 2 months ago](https://wordpress.org/support/topic/link-2-posts-programmatically/#post-5922619)
 * Status: not resolved