Skip to content

dfwood/i18n-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

I18n Example plugin

This plugin was created as an example to show working code for internationalization and localization in WordPress.

Hopefully, this will help serve as a learning tool on how WP handles translations.

Quick notes on language files

If you are including/compiling your own files, you will need to follow strict naming procedures.

  • MO files should be named {text-domain}-{locale}.mo
  • JSON files should be named {text-domain}-{locale}-{script-handle}.json

If you want, you may use a .po file editor such as PoEdit or similar to translate the .pot file into another language to test in WordPress.

Disclaimer: I only know very basic Slovak, as such translations may be inaccurate. Some were done with Google Translate. While my best attempts were made to properly translate the text (and avoid anything offensive), there may be inaccuracies. (Also, I know names are typically not translated, but I have too much fun with my name)

About

A quick WordPress plugin to show how to do internationalization in both PHP and JS in a WordPress plugin.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published