In CSS, identifiers (including element names, classes, and IDs in selectors) can contain only the characters [a-zA-Z0-9] and ISO 10646 characters U+00A0 and higher, plus the hyphen (-) and the underscore (_); they cannot start with a digit, two hyphens, or a hyphen followed by a digit. Identifiers can also contain escaped characters and any ISO 10646 character as a numeric code (see next item). For instance, the identifier "B&W?" may be written as "B\&W\?" or "B\26 W\3F".
.aaa-bbb,
.中くらい,
.300x300{width:300px; height:300px;}
既出ですが、名称に利用できるルールは下記があります。
4 CSS2 syntax and basic data types
4.1.3 Characters and case
http://www.w3.org/TR/1998/REC-CSS2-19980512/syndata.html
CSS3 module: Syntax
4.1. Characters and case
http://www.w3.org/TR/css3-syntax/
日本語については、アスキー以外のユニコード文字は不可となっていますので、要するにアルファベット以外の文字は不可ということでしょう。
また、数字およびハイフンと数字の組合せが名称の先頭にくるのも不可です。
日本語や全角スペースがセレクタに含まれている場合には終了ブロック( } )まで、属性や属性値の前後に含まれていると、直後の終了子( ;
)まで無視されると記憶しています。
==
2012年7月10日 18:51 Wataru Kanzaki <goo...@wi-wi.jp>:
> --
> このメールは Google グループのグループ「html5j.org」の登録者に送られています。
> このグループに投稿するには、html5-dev...@googlegroups.com にメールを送信してください。
> このグループから退会するには、html5-developer...@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/html5-developers-jp?hl=ja からこのグループにアクセスしてください。
>