2010-01-29 194 views
1

我正在构建this landing page,在第二段之后,我列出了我已将列表样式图像应用于li.actionItem的点,但是我得到的是默认光盘而不是我的图像。我知道这个网址正在工作,因为a)我以绝对的形式写出来,b)如果你输入绝对网址,你会得到图像(见这里)和c)我尝试应用图标作为背景图像,文字和工作。为什么我的list-style-image没有显示出来?

如果我必须(填充版本的背景图像),我最终可以做到这一点,但我宁愿把它写成列表式图像。此外,它只是让我发疯,为什么它不会以这种方式出现,我想知道。

任何想法或提示?谢谢!

这里是一目了然的相关标记...

  <ul id="introPoints"> 
       <li class="actionItem">performed more than <strong>500</strong> surgeries</li> 
       <li class="actionItem">set more than <strong>3,000</strong> fractured bones</li> 
       <li class="actionItem">mobilized more than <strong>90</strong> volunteers to Haiti</li> 
       <li class="actionItem">sent pastors from our DR hospital to minister to the victims</li> 
      </ul> 

ul#introPoints { 
list-style-image:url (http://blog.helpcurenow.org/images/campaigns/jan2010/haiticrisis/arrow-green-distress.gif); 
list-style-type:disc; 
} 

li.actionItem { 
    font-family:"Trebuchet MS", Arial, Helvetica, sans-serif; 
    color:#6e5e4c; 
    font-size:14px; 
    text-align:justify; 
    width:580px; 
    font-style:italic; 
    margin:10px 0px 10px 20px; 
    text-indent:15px; 
} 
li.actionItem strong { 
    color:#dd7439;  
} 

回答

1

这可能是也可能不是问题,但根据css grammar你不能有url和左括号之间的空间。 。

所以做到这一点:

url(/someurl) 

不是这个:

url (/someurl) 
+0

是的,固定它。谢谢!!! – 2010-01-29 20:13:01

4

尝试使用背景图像。无论如何,list-style-image永远不会正确排列。

background-image:url(...); 
background-repeat:no-repeat; 
background-position:0px 0px 
相关问题