I’m making a site with Twenty Eleven and want to have the sidebar on the right for some pages and on the left for others. More specifically on the left for Arabic pages and on the right for English pages (I am using WPML). As I could not find control of this in the theme I started reading about creating additional page templates – it would be useful for me to change the logo image and the sidebar content per language as well now that I think about it. I’ve nearly understood what I have read in Codex and forums but it is still a little complex for and I don’t have a clear picture of the steps. Can anyone help me here ?
I guess it could be done by making a page template that can be selected in the ‘Templates’ dropdown of ‘Page Attributes’ when creating or editing a page.
OR there could be an IF statement to pick up the url’s with /ar/ for the arabic language.
thanks to anyone who can answer this
I followed the instructions in the article, which was brilliant. It works just as described, except …
I went to an Arabic page and applied the right-sidebar but it also changed the English page linkd to it.
Also, with th ecurrrent structure, the home page containing th eblog was not selectable as a page and so has the default template, English and Arabic.
If I added Arabic pages independently of their English translations the the Menu would not be synched (WPML).
It looks like an if statement based on url: …/ar/ might be the simplest answer, but i’m not yet versed enough to write it.
I definitely learnt something I’ll apply to websites in the future but I still have problems with this English/Arabic site.
Directed homepage to a static page called home, so that I could access it. I now have right sidebars for Arabic and left sidebars for English.
I am still looking for the answer to hosting diffrent sidebar content for the two languages via an IF statement
- The topic ‘sidebar R/L, If statement & alternative page templates’ is closed to new replies.