在我的页面中间,我有一个包含列表的<div>。当我查看页面源代码时,我看到了那里的所有代码,但实际上在浏览器中呈现给用户的唯一内容是“品牌”h4标题。(请注意,这实际上是动态生成的,这是示例输出)
此外,我已经在几台不同的机器上检查了几种不同的浏览器,所以我认为这不是问题所在
为什么我的列表没有显示,是不是有什么明显的遗漏?
<div class="filter-group filter-group-brand">
<h4>Brand</h4>
<ul class="nav-brand ">
<li class="collection-container aimpoint active ">
<div class="collection-name">
<a title="Narrow selection to products matching tag aimpoint"
href="/collections/firearm-accessories/aimpoint">
<i class="check-icon"></i> Aimpoint
</a>
</div>
</li>
<li class="collection-container aimshot active ">
<div class="collection-name">
<a title="Narrow selection to products matching tag aimshot"
href="/collections/firearm-accessories/aimshot">
<i class="check-icon"></i> Aimshot
</a>
</div>
</li>
<li class="collection-container barska-optics active ">
<div class="collection-name">
<a title="Narrow selection to products matching tag barska-optics"
href="/collections/firearm-accessories/barska-optics">
<i class="check-icon"></i> Barska Optics
</a>
</div>
</li>
</ul>
</div>发布于 2013-08-29 13:45:55
在没有任何CSS的情况下,这样做效果很好,<li>元素将会出现。当你遇到显示错误/问题时,总是考虑给出你的CSS代码
您的CSS文件中一定有错误。检查以下类的display:none或hidden属性等:collection-name、new-brand、collection-container。
此外,您还有空的<i>标记,以防出现错误。
https://stackoverflow.com/questions/18503085
复制相似问题