Easily create multilingual sites with WordPress. 1 – Localize theme strings Before installing a plugin on your blog, the first thing to do is to localize theme strings. PHP and the Gettext tool (which allow easy string translation) have two functions: _e() and __(). The only difference between _e() and __() is that _e() echo a string while __() is used to assign a string to a variable. Let’s say your theme have the following code: <div class="content"><h1>Welcome to my site! </h1><p>I hope you'll like it. </p></div><! What you have to do is to wrap all strings into the _e() or __() functions, as shown in the example below: Once done, your string will be recognized by the WPML plugin (we’re going to install it) as translatable strings. 2 – Install and configure the WPML plugin Now that your theme is fully localized, the next step is to install the WPML plugin, which will make our blog multilingual. 3 – Translate theme strings Once done, you now have to translate your theme strings in French. 4 – Translate site content.
Awesome WordPress hacks to make your blogger life easier - CatsWhoCode.com. Hardcode to make WordPress faster Hardcoding is generally not a good practice, however in the case of an established website, hardcoding your blog url, site url, template path and stylesheet path will make your blog run faster. When a function such as bloginfo('url') is called, WordPress executes a query to your database to get the value, except if the value can be found on your wp-config.php file. To hardcode those constants, edit wp-config.php and paste the following (Don’t forget to change the values!) : define('WP_HOME', ' // blog url define('WP_SITEURL', ' // site url define('TEMPLATEPATH', '/absolute/path/to/wp-content/themes/cwc5'); define('STYLESHEETPATH', '/absolute/path/to/wp-content/themes/cwc5'); Source: Set HTML editor as the default I know a lot of tech-savvy persons who don’t really like WordPress “visual” editor.
<? WPML Multilingual CMS. qTranslate. Global Translator. Les options pour un site bilingue ou multilingue WordPress | Diane Bourque. Dans cet article, je parle de sites bilingues et multilingues WordPress. PUBLIÉ LE 6 juillet 2010 MIS À JOUR 20 janvier 2014 Les sites bilingues ou multilingues dans WordPress Je connais plusieurs méthodes de faire un site WordPress bilingue ou multilingue: 1. En créant 2 sites WordPress distincts comme et Chaque site est géré par une installation WordPress distincte et les deux sont reliés par des boutons FRANÇAIS | ENGLISH ou images de drapeaux. 2. 3. 4. 5. 6.
Bye Bye qTranslate L‘extension qTranslate est une extension WordPress qui permet la publication d’un site bilingue ou multilingue. 1. Quoique le site était bilingue, il n’y avait en réalité qu’un article publié dans deux langues. <! Les options pour un site bilingue ou multilingues WordPress Options for a bilingual or multilingual site in WordPress - Quel malheur! Après maintes recherches, je n’ai pas trouvé de réponse à ce dilemme. 2. 3. L’extension WPML – ma préférée Conclusion.