今天又验证了下首页,发现又不符合XHTML1.0标准了,问题的根源在于我修改了分类输出的代码:
<h2>分类</h2>
<ul class="counts">
    <?php wp_list_cats(‘sort_column=name&optioncount=1&hierarchical=0&feed_image=/images/feed.gif’); ?>
</ul>

这样输出的图片的内容为:
<img src=‘/images/feed.gif’ />

这个输出不符合XHTML1.0标准,需要ALT属性,看了下Wordpress的源代码(template-functions-category.php)中wp_list_cats的实现,发现要输出ALT就必须指定Feed选项的值,修改后的结果:
<h2>分类</h2>
<ul class="counts">
    <?php wp_list_cats(‘sort_column=name&optioncount=1&hierarchical=0&feed_image=/images/feed.gif&feed=Feed’); ?>
</ul>