[wordpress插件] Bunny’s Language Linker兔子的语言链接器

wordpress 插件 文章 2020-03-14 03:00 425 0 全屏看文

AI助手支持GPT4.0

评分
0
描述

This plugin assumes you have a site in two or more languages, and that you are using a separate WordPress install for each language.

此插件假定您拥有使用两种或更多种语言的网站,并且您针对每种语言使用单独的WordPress安装。

It helps you create links between the same pages in different

它可以帮助您在不同页面的相同页面之间创建链接

language versions.

语言版本。

You should have a pattern of parallel sites with urls like http://stephanie-booth.com/en/, http://stephanie-booth.com/de/, http://stephanie-booth.com/

您应该使用网址类似的并行站点模式,例如http://stephanie-booth.com/en/、http://stephanie-booth.com/de/、http://stephanie-booth.com/

fr/.

fr /。

Maybe the page

也许页面

http://stephanie-booth.com/en/about is equivalent to the page http://stephanie-booth.com/fr/a-propos.

http://stephanie-booth.com/en/about等效于http://stephanie-booth.com/fr/a-propos页面。

The plugin adds a DBX box in the edit/create page admin form, named “Other Language Slugs”.

该插件在编辑/创建页面管理表单中添加一个DBX框,名为“其他语言插件”。

In


this case, you’d edit the “about” page, and paste the fr slug (“a-propos”) in the appropriate field.

在这种情况下,您需要编辑“关于”页面,然后将fr slug(“ a-propos”)粘贴到适当的字段中。

The plugin will then display a small link to the page in the other language at the bottom of your page, or in your menu bar if you’re using a Sandbox-based theme.

然后,该插件将在页面底部以其他语言显示一个指向页面的小链接,如果您使用的是基于沙盒的主题,则在菜单栏中。

Careful!

小心!

This only works for Pages, not posts!

这仅适用于Pages,不适用于帖子!

For intelligent user redirection when they land on the home page, you might want to try using the technique described here: http://climbtothestars.org/archives/2007/12/28/browser-language-detection-and-

对于智能用户重定向,当他们登陆主页时,您可能想要尝试使用此处描述的技术:http://climbtothestars.org/archives/2007/12/28/browser-language-detection-and-

redirection/

重定向/

Future Development

未来发展

Here’s what I’d like this plugin to do, someday:

这是我希望这个插件一天完成的事情:

    • automatically capture URLs like http://stephanie-booth.com/en/a-propos and redirect them to http://stephanie-booth.com/en/about (that's what happens when people edit URLs directly, just

    • 自动捕获诸如http://stephanie-booth.com/en/a-propos之类的URL,并将其重定向到http://stephanie-booth.com/en/about(这是人们直接编辑URL时发生的情况,

      replacing

      替换

      the language code — I do it all the time)

    • 语言代码-我一直都这样做)

安装步骤

    1. Upload the language-linker directory into /wp-content/plugins/
    2. 语言链接器目录上传到 / wp-content / plugins /

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

    5. Edit the settings at the beginning of the plugin file to indicate what languages you are working with.
    6. 在插件文件的开头编辑设置,以指示您使用的语言。

    7. Start linking!
    8. 开始链接!

下载地址
https://downloads.wordpress.org/plugin/bunnys-language-linker.zip
-EOF-

AI助手支持GPT4.0