<!DOCTYPE html>
<html>
<head>
<style>
a:after {content: " (" attr(href) ")";}
</style>
</head>
<body>
<p><a href="https://www.lmonkey.com/">学习猿地</a> 包含免费的教程和参考.</p>
<p><b>请注意:</b> 只有在指定了!DOCTYPE的情况下,IE8才支持content属性.</p>
</body>
</html>
<!DOCTYPE html>
<html>
<head>
<style>
body {counter-reset:section;}
h1 {counter-reset:subsection;}
h1:before
{
counter-increment:section;
content:"Section " counter(section) ". ";
}
h2:before
{
counter-increment:subsection;
content:counter(section) "." counter(subsection) " ";
}
</style>
</head>
<body>
<p><b>请注意:</b> IE8仅在指定了!DOCTYPE的情况下才支持这些属性.</p>
<h1>HTML 教程</h1>
<h2>HTML 教程</h2>
<h2>XHTML 教程</h2>
<h2>CSS 教程</h2>
<h1>Scripting 教程</h1>
<h2>JavaScript</h2>
<h2>VBScript</h2>
<h1>XML 教程</h1>
<h2>XML</h2>
<h2>XSL</h2>
</body>
</html>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="en">
<head>
<style type="text/css">
q:lang(en)
{
quotes: "~" "~" "'" "'";
}
</style>
</head>
<body>
<p><q>这是一个 <q>强壮的</q> 男人.</q></p>
<p><b>注意:</b>当声明了!DOCTYPE 时, IE8 才支持这些属性。</p>
</body>
</html>
© 著作权归作者所有