trying to select html language attribute for language-specific styling using the css :lang() pseudo-class selector but it is not working:

html:
<html class="js" xml:lang="zh-hans" xmlns="http://www.w3.org/1999/xhtml">

css:

html{font-family: Helvetica, Arial, sans-serif;}
html:lang(zh-hans){font-family: SimSum-18030, SimHei, serif;}

I have not succeeded in my attempts at language-specific styling so it is likely that I am making a mistake.

I noticed a patch to add css class to body tag but don't see the point unless the above method of selection is not valid.

Thank you

Comments

parkerjdru’s picture

still struggling with this. Here is the bilingual site: http://openarch.com/ . Would like to style the chinese and english independently, but above css selection method is not doing anything.

would really appreciate any help or kind advice on where i should post this question if not here. I have already moved from this from the general forum after receiving no responses. I am pretty sure this is a stupid question, but it is taking me weeks to solve.

desperate thanks in adv.

joseph.olstad’s picture

Issue summary: View changes
Status: Active » Closed (outdated)