01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
2008-09-03 Wed
■ google-code-prettify は言語を限定して使用できる
class="prettyprint lang-html" を指定すると html に限定する。
"c", "cc", "cpp", "cs", "cyc", "java", "bsh", "csh", "sh",
"cv", "py", "perl", "pl", "pm", "rb", "js",
"html", "html", "xhtml", "xml", "xsl"
が定義されている。
■ xhtml での google-code-prettify
google-code-prettify で を出力しているところがある。
xhtml では が定義されてない。
xhtml で google-code-prettify を使うと未定義の実態を参照することになる。
.replace(lastWasSpace ? startOrSpaceRe : adjacentSpaceRe, '$1 ');
のように変更してみた。
Google Chrome で見て動いてないのに気づいた。
「xhtml では   が定義されてない。」ってのが分からなかった。
Referrer (Inside):
[2009-10-15-1]