我有一个getResources块,看起来像:
<a href="[[+tv.galimage]]" class="fancybox galitem" title="[[+pagetitle]]"> <div class="galimage" style="background-image: url('[[+tv.galimage]]')"></div> </a>但由于某种原因,前两个资源出现在A标签之外的div,例如:
<a href="images/Gallery/ferrari1.jpg" class="fancybox galitem" title="Image 2"> </a> <div class="galimage" style="background-image: url('images/Gallery/ferrari1.jpg')"></div>然而,在前两个和使用相同模板块之后的所有其他资源都按预期显示,例如:
<a href="images/Gallery/porsche.jpg" class="fancybox galitem" title="Image 2"> <div class="galimage" style="background-image: url('images/Gallery/porsche.jpg')"></div> </a>有谁知道为什么会发生这种情况以及我能做些什么来解决它?
(显然,我已经尝试清除缓存。此外,这似乎并未与特定资源隔离。无论哪个资源首先出现在列表中,都会发生这种情况。)
I have a getResources chunk that looks like:
<a href="[[+tv.galimage]]" class="fancybox galitem" title="[[+pagetitle]]"> <div class="galimage" style="background-image: url('[[+tv.galimage]]')"></div> </a>but for some reason the first two resources appear with the div outside of the A tags, eg:
<a href="images/Gallery/ferrari1.jpg" class="fancybox galitem" title="Image 2"> </a> <div class="galimage" style="background-image: url('images/Gallery/ferrari1.jpg')"></div>Yet every other resource following these first 2 and using the same template chunk appears as expected, eg:
<a href="images/Gallery/porsche.jpg" class="fancybox galitem" title="Image 2"> <div class="galimage" style="background-image: url('images/Gallery/porsche.jpg')"></div> </a>Would anyone know why this is occurring and what I could do to fix it?
(Obviously, I have tried clearing the cache. Also, this does not appear to be isolated to a particular resource. It occurs no matter which resources appear first in the list.)
最满意答案
将块元素( div )包装div联标记中是一个奇怪的问题。 把div改为span ,没关系。
It was a weird issue with wrapping a block element (div) in an inline a tag. Changed div to span and it was ok.
更多推荐
a>,<a,资源,div>,电脑培训,计算机培训,IT培训"/> <meta name="descri
发布评论