March 20, 2015 at 2:57 am
Hi Ben 🙂
Just a quick question – I really want to use Virtue (or Pinnacle BTW) for a conference website I’m building, but this website would need a localisation in Hebrew – hence my question: does either of the themes support Right To Left writing?
I’ll obviously use WPML for the Hebrew localisation, but the theme still needs to also support RTL writing (*Login to see link
Ok, edit – I just read following on the WPML blog (the link above):
Now that your content is translated, it’s time to move our attention to the theme.
This little line does most of the magic:
<html dir="rtl" lang="he-IL">
The dir=”rtl” attribute tells the site that the display direction for the entire site is Right to Left. Browsers understand it and will flip everything to right direction.
This single PHP line, from header.php, makes it happen:
<html <?php language_attributes(); ?>>
The call to language_attributes inserts the dir and lang attributes. The values come from the core .mo file. If you have the correct .mo files for WordPress, you get the correct values for these attributes.
If your theme’s HTML and CSS follow ‘safe’ practices, this is really all you need. By safe, I mean no absolute positioning or widths. If you must use absolutes, you may consider loading different CSS per language.
So I guess my question is now: can I safely do this with Virtue or Pinnacle (premium versions) without breaking everything, including mobile responsiveness?
Thanks!
Anne