Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

How can I remove the disc from <li> using CSS?

Featured Replies

I'd like it to work on both IE and Firefox. Here's what I've tried:

 

 

ul li {

list-style: none;

}

 

 

doesn't work... any ideas?

 

Also, how would I replace the default disc or circle with an image?

Try

 

ul li {
list-style-image:url(/your/image/path/here);
}

Have you got your html for us to have a little look at?

  • Author

ul#mainlevel-nav li {

display: inline;

height: 49px;

width: 130px;

list-style: none;

list-style-image: none;

list-style-type: none;

}

 

ul#mainlevel-nav li a {

background: url('../images/tabs.png') no-repeat;

display: block;

float: left;

width: 130px;

height: 49px;

line-height: 42px;

list-style: none;

}

 

 

 

And the html:

 

<div id="menuarea">

<ul id="mainlevel-nav">

 

<li><a href="/practicesite/index.php?option=com_content&view=article&id=25&Itemid=28" class="mainlevel-nav" >About Me!</a></li>

 

<li><a href="/practicesite/index.php?option=com_content&view=article&id=22&Itemid=29" class="mainlevel-nav" >Features</a></li>

 

<li><a href="/practicesite/index.php?option=com_newsfeeds&view=newsfeed&id=1&feedid=1&Itemid=18" class="mainlevel-nav" >News</a></li>

 

<li><a href="/practicesite/index.php?option=com_content&view=article&id=27&Itemid=30" class="mainlevel-nav" >The Community</a></li>

 

</ul>

</div>

Did you try the method I posted? That should work just fine.

 

EDIT: Also, if you want to simply remove the circle input this:

 

ul li {
list-style-type:none;
}

 

if you want to take away the styling/alignment of them completely just put this code:

 

ul li {
list-style-type:none;
padding:0px;
}

try below eg. I think it will work.

eg 1:--

HTML

 

<ul>
   <li>Lorem ipsum dolor sit amet</li>
   <li>Consectetuer adipiscing elit. Etiam sollicitudin</li>
   <li>Capibus velit. Praesent eget dui.</li>
   <li>Duis non elit et massa ultrices vehicula.</li>
   <li>Aliquam fermentum ipsum auctor enim.</li>
</ul>

css

 

ul {
   list-style-type:square;
}

 

 

eg 2:----

 

CSS

 

ul{
   list-style:none;
   margin:0 0 1em 15px;
   padding: 0;
}
ul li{
   line-height:1.3em;
   margin: .25em 0;
   padding: 0 0 0 15px;
   background:url(scho-arrow.gif) no-repeat 0 7px;
}

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.