[wordpress插件] Bogo波哥

wordpress 插件 文章 2020-03-08 11:50 588 0 全屏看文

AI助手支持GPT4.0

评分
92
描述

https://ideasilo.wordpress.com/bogo/

https://ideasilo.wordpress.com/bogo/

Bogo is a straight-forward multilingual plugin for WordPress.

Bogo是WordPress的简单易用的多语言插件。

The core of WordPress itself has the built-in localization capability so you can use the dashboard and theme in one language other than English.

WordPress的核心本身具有内置的本地化功能,因此您可以使用英语以外的一种语言使用仪表板和主题。

Bogo expands this capability to let you easily build a multilingual blog on a single WordPress install.

Bogo扩展了此功能,使您可以在单个WordPress安装上轻松构建多语言博客。

Here are some technical details for those interested.

以下是一些有兴趣的技术细节。

Bogo plugin assigns one language per post.

Bogo插件为每个帖子分配一种语言

It plays nice with WordPress – Bogo does not create any additional custom table on your database, unlike some other plugins in this category.

它可以与WordPress配合使用-与该类别中的某些其他插件不同,Bogo不会在数据库上创建任何其他自定义表。

This design makes Bogo a solid, reliable and conflict-free multilingual plugin.

这种设计使Bogo成为可靠,可靠且无冲突的多语言插件。

Getting Started with Bogo

Bogo入门

    1. Install language files

      安装语言文件

      First, make sure you have installed language files for all languages used in your site.

      首先,请确保已安装网站中使用的所有语言的语言文件。

      If you have a localized version of WordPress installed, you should already have these files for that language.

      如果您已安装WordPress的本地化版本,则应该已经拥有该语言的这些文件。

      If you don’t have language files yet, you can install them via Bogo’s admin page (Languages > Installed Languages).

      如果您还没有语言文件,则可以通过Bogo的管理页面(“语言”>“已安装的语言”)进行安装。

    2. Select your language for admin screen (dashboard)

      为管理屏幕(仪表板)选择您的语言

      Bogo allows each user to select a language for his/her own WordPress admin screen.

      Bogo允许每个用户为他/她自己的WordPress管理屏幕选择一种语言。

      Logged-in users can switch languages from the drop-down menu on the Admin Bar.

      登录的用户可以从管理栏上的下拉菜单切换语言。

      If the Admin Bar is hidden, you can also switch language on your Profile page.

      如果隐藏了管理栏,还可以在“个人资料”页面上切换语言。

    3. Translate posts and pages

      翻译帖子和页面

      You can translate posts and pages into the languages you have installed.

      您可以将帖子和页面翻译成已安装的语言。

      WordPress saves the contents of each post or page as usual, but Bogo adds ‘_locale’ post_meta data.

      WordPress照常保存每个帖子或页面的内容,但Bogo添加“ _locale” post_meta数据。

      The ‘_locale’ holds the language code of the post.

      “ _locale”保存帖子的语言代码。

    4. Add a language switcher to your site

      将语言切换器添加到您的网站

      You will want to place a language switcher on your site that allows visitors to switch languages they see on the site.

      您将需要在您的网站上放置一个语言切换器,以允许访问者切换他们在网站上看到的语言。

      The easiest method is using the Language Switcher widget included in Bogo.

      最简单的方法是使用Bogo中包含的Language Switcher小部件。

      Bogo also provides a shortcode “[bogo]” to allow you to place a language switcher inside a post or page content by simply inserting [bogo].

      Bogo还提供了一个简码“ [bogo]”,使您可以通过简单地插入[bogo]将语言切换器放置在帖子或页面内容中。

      To embed a language switcher directly into your theme’s template file, use this shortcode as follows:

      要将语言切换器直接嵌入主题模板文件中,请按以下方式使用此短代码:

        <?php echo do_shortcode('[bogo]'); 

      ?>

      ?>

安装步骤

    1. Upload the entire bogo folder to the /wp-content/plugins/ directory.
    2. 将整个 bogo 文件夹上载到 / wp-content / plugins / 目录。

    3. Activate the plugin through the ‘Plugins’ menu in WordPress.
    4. 通过WordPress中的“插件”菜单激活插件。

下载地址
https://downloads.wordpress.org/plugin/bogo.3.2.1.zip
-EOF-

AI助手支持GPT4.0