Linux 软件免费装
Banner图

Parly — Simple Multi Language

开发者 sudosw
更新时间 2026年8月1日 01:36
PHP版本: 7.4 及以上
WordPress版本: 7.0
版权: GPLv2 or later
版权网址: 版权信息

标签

translation multilingual bilingual language switcher hreflang

下载

1.0.2 1.0.3

详情介绍:

Parly is a lightweight alternative to heavy multilingual plugins. Instead of intercepting your HTML or forcing a translation interface on you, it uses the simplest model possible: each translation is a normal WordPress page, duplicated from the original and edited with the editor you already use — Gutenberg, Classic, or any page builder. How it works
  1. Register your languages (name, ISO code, optional flag emoji).
  2. On any post or page, click "+ create translation" in the Translations metabox. Parly duplicates the content (including featured image, template and custom fields) as a draft linked to the original.
  3. Translate it with your normal editor and publish.
  4. Visitors switch languages via the floating button, a menu item, or the [parly_switcher] shortcode.
Features Limitations — read before installing Parly keeps things simple on purpose, and that comes with honest trade-offs: Functions for developers All helpers are safe to call from any theme or plugin (guard with function_exists() if your theme may run without Parly):

安装:

  1. Upload the plugin files to /wp-content/plugins/parly-simple-multi-language, or install through the WordPress plugins screen directly.
  2. Activate the plugin — you will land on the "Get started" guide.
  3. Confirm your site's main language, then register your other languages in the Languages tab.
  4. Open any post or page and use the Translations metabox to create translated versions.

屏幕截图:

  • Languages tab: register languages with name, ISO code and flag emoji, and see how many pages exist in each.
  • Theme texts: scan the site and register strings from the theme.
  • Bulk translation: export, translate with AI using the built-in prompt, import.

升级注意事项:

1.0.1 Requires WordPress 6.9+ now (was 5.8). Fixes an output-buffering issue on translated pages that could leave a buffer open past the request. 1.0.0 Initial release.

常见问题:

Does it work with Elementor / Divi / WPBakery / other page builders?

Yes. Duplication copies all post meta, which is where page builders store their layouts, so each translation is edited with the same builder as the original. For AI bulk translation, note that builders like WPBakery and Divi keep visible text inside shortcodes (e.g. [nectar_split_heading text="..."]); Parly's export and prompt tell the AI to translate that text while preserving the shortcode structure. After importing a page-builder page, review it and, if a heading did not translate, open it in the builder and adjust — editing text where it actually lives is always the most reliable.

Can I show a different navigation menu per language?

Yes. Create one menu per language in Appearance → Menus, then map them in the Menus tab (per theme location, per language). Parly swaps the menu automatically based on the language of the page being viewed.

Does deleting a language delete my translated pages?

Removing a language shows a confirmation screen listing every affected page. By default pages are moved to the trash (recoverable); you can optionally delete them permanently, which requires typing the language code to confirm.

How does the AI bulk translation work?

Export generates a JSON file with your content and embedded instructions for the AI, plus a ready-to-paste prompt shown on screen. You attach the file to any AI chat, paste the prompt, and upload the returned JSON. Parly validates the file, repairs common formatting mistakes, and creates translations as drafts (or published, your choice). No API keys, no external calls — the plugin never contacts any server.

Does the plugin send any data to external services?

No. Parly makes no external requests. The AI translation step happens entirely outside the plugin, in whatever tool you choose. The site scanner only fetches pages of your own site.

Does the plugin set cookies?

One functional cookie (parly_lang, 30 days) may be set in two situations: when automatic browser detection is enabled (to make sure detection happens only once) and when a visitor manually picks a language in the switcher (to remember the choice). It contains only a language code and is never sent to third parties.

My theme has hardcoded text in template files. Can Parly translate it?

Two options. First, the Theme texts tab: scan a page, register the texts it finds, and Parly replaces them in the rendered HTML on translated pages — no theme changes needed. Second, for text a developer controls, the parly_t( array( 'en' => 'About us', 'pt' => 'Sobre nós' ) ) helper returns the string matching the language of the page being viewed. If a theme cannot be edited and the scanner does not reach the text, a plugin with a different (automatic, external-service) approach such as Weglot may fit better — different trade-offs, usually a paid subscription.

The translated version of my homepage renders empty. Why?

If your theme builds a page's content inside a custom template (for example front-page.php, or a page-home.php matched by the home slug), WordPress only uses that template for the original page. A duplicated translation has a different slug (e.g. home-2) and is not the configured front page, so it falls back to the generic page.php and, if the content field is empty, renders nothing. Point the theme at the original page with parly_get_original_id(). In page.php (or wherever the branch lives): $parly_id = function_exists( 'parly_get_original_id' ) ? parly_get_original_id() : get_queried_object_id(); if ( (int) get_option( 'page_on_front' ) === $parly_id ) { get_template_part( 'template-parts/home' ); return; } Now every language variant reuses the same custom markup. Use parly_t() / parly_get_current_lang() inside that markup (or register the visible strings under Theme texts) so the reused template shows text in the current language. parly_is_translation() is also available if you only want to branch on translated views.

What happens if a page has no translation in a language?

The switcher link for that language falls back to the site homepage. Unpublished (draft) translations are never linked.

Is Parly compatible with WPML, Polylang or other multilingual plugins?

No. Running two multilingual systems at once causes conflicts. Parly shows a notice if it detects one active, and you should use only one at a time.

更新日志:

1.0.3 1.0.2 1.0.1 1.0.0