Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
WordCamp Geneva: Recent I18N Improvements in Wo...
Search
Pascal Birchler
November 18, 2016
Technology
0
130
WordCamp Geneva: Recent I18N Improvements in WordPress
Slides for my presentation at WordCamp Geneva, Switzerland, on November 18th, 2016.
Pascal Birchler
November 18, 2016
Tweet
Share
More Decks by Pascal Birchler
See All by Pascal Birchler
Client-side media processing in WordPress
swissspidy
0
56
Democratizing Performance
swissspidy
0
74
On Multilingual WordPress Sites
swissspidy
0
56
WordPress Internationalization Workflows
swissspidy
0
3.2k
WordPress Internationalization Workflows
swissspidy
0
120
WordPress Internationalization Workflows
swissspidy
1
1.1k
On Internationalization and Localization
swissspidy
0
250
Internationalisation in the Age of Gutenberg
swissspidy
0
300
Internationalization Introduction at WordCamp Bern
swissspidy
0
110
Other Decks in Technology
See All in Technology
LangSmith×Webhook連携で実現するプロンプトドリブンCI/CD
sergicalsix
1
140
プロダクトエンジニアリング組織への歩み、その現在地 / Our journey to becoming a product engineering organization
hiro_torii
0
130
Model Mondays S2E03: SLMs & Reasoning
nitya
0
230
生成AIで小説を書くためにプロンプトの制約や原則について学ぶ / prompt-engineering-for-ai-fiction
nwiizo
4
3.2k
解析の定理証明実践@Lean 4
dec9ue
1
190
AI導入の理想と現実~コストと浸透〜
oprstchn
0
140
なぜ私はいま、ここにいるのか? #もがく中堅デザイナー #プロダクトデザイナー
bengo4com
0
1.2k
rubygem開発で鍛える設計力
joker1007
2
260
モバイル界のMCPを考える
naoto33
0
290
Node-REDのFunctionノードでMCPサーバーの実装を試してみた / Node-RED × MCP 勉強会 vol.1
you
PRO
0
120
KubeCon + CloudNativeCon Japan 2025 Recap
ren510dev
1
290
Geminiとv0による高速プロトタイピング
shinya337
0
180
Featured
See All Featured
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
20
1.3k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
26
2.9k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
31
1.3k
Optimising Largest Contentful Paint
csswizardry
37
3.3k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
507
140k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
181
53k
Become a Pro
speakerdeck
PRO
28
5.4k
Designing for Performance
lara
609
69k
The Pragmatic Product Professional
lauravandoore
35
6.7k
The World Runs on Bad Software
bkeepers
PRO
69
11k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
657
60k
Speed Design
sergeychernyshev
32
1k
Transcript
Internationalization Improvements in WordPress 4.6 and Beyond
Pascal Birchler @swissspidy
Language Packs, the Early Days
Automatic Updates
None
Change Your Mind
None
Language Packs for Plugins and Themes
WordPress 4.6
Localized Datepicker
None
Language Packs More Important Than Ever
Loading Translations in Different Order
load_plugin_textdomain( 'myplugin', false, 'languages' )
wp-content/plugins/myplugin/ languages/… ! wp-content/languages/plugins/…
wp-content/languages/plugins/… ! wp-content/plugins/myplugin/ languages/…
Just-in-time Loading for Translations
wp-content/languages
// Do stuff. _e( 'Hello World’, 'myplugin' ); // …Magic
happens… // Prints: Hallo Welt
wp-content/languages/plugins/myplugin-de_DE.mo
Good bye, load_plugin_textdomain()
WordPress 4.7
User Admin Language
None
None
Back End: Français Front End: English
None
Locale Switching
switch_to_locale()
$switched = switch_to_locale( get_user_locale() ) // Do stuff. if (
$switched ) { restore_previous_locale(); }
Send Emails In the User’s Language
What About the Admin Toolbar?
None
Beyond
Preferred Languages
None
JavaScript Internationalization
// PHP: wp_localize_script( 'myplugin-script', '_myPluginL10n', array( 'helloWorld' => __( 'Hello
World','myplugin' ) ) ); // JS: alert( _myPluginL10n.helloWorld );
if ( 1 == number ) { use( _myPluginL10n.singularString );
} else { use( _myPluginL10n.pluralString ); }
wp.i18n.__( 'Hello World' )
wp-content/languages/plugins/myplugin-de_DE.json
Good bye, wp_localize_script()
User Timezones
None
Questions?
Thanks!