Support Log in

Linking an Already-Written Translation

User Guide
Prefer video? Watch the Lang Forge tutorials 9 short guides covering every feature Watch

Sometimes translations already exist on your site but are not connected to their originals through Lang Forge. This happens when you migrate from another multilingual plugin, when a team member creates a translated post manually instead of using the + Create button, or when you merge content from multiple WordPress installations into one. The Link button in the Language metabox lets you manually connect these independent posts into a translation group so that Lang Forge treats them as related language versions.

Understanding when and how to link existing translations is especially important during a migration. If your site previously used a different multilingual plugin (like WPML, Polylang, or TranslatePress) and the translation links were not preserved during the switch, you may have dozens or hundreds of posts that need reconnecting.

When you would use this feature

  • You imported content from another multilingual plugin and the translation relationships were not preserved
  • A team member created a translated post using the standard “Add New” button instead of the Lang Forge + Create button
  • You are migrating from a site where translations existed as separate, unlinked posts in different categories
  • You merged content from two separate WordPress installations into one site
  • You received translated content from a freelance translator who created the posts independently

Step-by-step: Linking two existing posts as translations

  1. Find the ID of the translated post. It is the number after post= in the address of its edit screen
  2. Open the original post, the one in your default language, in the WordPress editor
  3. In the Language metabox, find the row of the language you want to link. A language with no translation yet shows a dash and the buttons + Create and Link
  4. Click Link. A prompt asks “Enter the Post ID to link as translation:”. Enter the ID and confirm. If you cancel the prompt or enter something that is not a number, nothing happens
  5. Lang Forge sets the language of that post to the language of the row, links it to the original, and reloads the page. You need permission to edit both posts
  6. The row now shows the title of the linked post as a link to its edit screen, in place of the dash and the buttons

Step-by-step: Unlinking a translation

If you linked the wrong post by mistake, you can remove the link without changing either post:

  1. Open the original or the translation in the editor
  2. In the Language metabox, find the row of the linked post
  3. Click the × button at the end of the row (its tooltip is Unlink)
  4. Confirm the question “Unlink this translation?” in the dialog that appears
  5. The page reloads. The two posts keep their content and are no longer connected as translations

Real-world example: Migrating from another plugin

Imagine your company’s site was built with WPML and you are switching to Lang Forge. You have 50 English pages and 50 Spanish translations. After deactivating WPML and activating Lang Forge, the Spanish pages still exist in your database, but Lang Forge does not know they are translations of the English pages. You would go through each English page, click Link in the Spanish row of the Language metabox, and enter the ID of the corresponding Spanish page. Link also sets the language of the Spanish page, so it does not have to be set first.

If your site was built with TranslatePress, run Lang Forge → Tools → Migration first. TranslatePress stores most translated content as string records instead of separate WordPress posts, so Lang Forge creates per-language post copies, links them into translation groups, imports the language settings, and moves TranslatePress gettext strings into String Translation.

Things to check before you link

  • Link is on the original only. The Link and + Create buttons are drawn only when you edit a post in your default language, and only in the row of a language that has no translation yet. A row that is already linked shows the title of the linked post and an unlink button instead
  • Check the ID and the post type. The Link button refuses a post that cannot be a translation of the original, and a message says why: the original itself, a post that does not exist, a post of another type (a page for a post, for example), and a post in the Trash. Nothing is changed in that case. Any other post you enter gets the language of the row and is linked to the original, so check the ID before you confirm
  • A post that is already linked. If the post you enter already has translations of its own, the two groups of translations are merged. To take a post out of the group again, use its unlink button

> Good to know: Linking and unlinking never edit, move, or delete the text of a post. Link sets the language of the post you enter, and both actions change the record that connects the posts.

From the command line

The WP-CLI command wp langforge set-language POST_ID LANGUAGE sets the language of a post, wp langforge link POST_ID_1 POST_ID_2 links two posts as translations, and wp langforge unlink POST_ID LANGUAGE removes the translation in that language from the group of the post.

—

Forge AI Assistant Online

Hi! I'm the Lang Forge AI assistant. Ask me anything about the plugin — setup, features, troubleshooting, or development.

Just now
Powered by Forge AI · Browse docs