How to override CSS style (list-style-type) set in main CSS file

I am trying to override a CSS setting for lists in one of my pages. In my master CSS file, I have set the following rule: ul, li { list-style-type: none; } I have one page, where I DO want to set the style of the list - I would also like to increase the spacing between those list items on that single page. The page looks like this:


  • line 1
  • line 2
  • line 3
  • line 4
So far I have tried the following: - Adding the style to the containing UL tag - Adding the style BOTH to the containing UL tag and each LI tag None has worked so far. Since I have over 1K pages referencing the main.css file, I do not want to change it. But how can I override the settings for the specific list items in my page? Why am I not able to override the settings in my main.css if even I apply the style at the element itself?

以上就是How to override CSS style (list-style-type) set in main CSS file的详细内容,更多请关注web前端其它相关文章!

赞(0) 打赏
未经允许不得转载:web前端首页 » HTML5 答疑

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

前端开发相关广告投放 更专业 更精准