I have blocks but i want to remove the bullets and just have the listing. Does anyone know how to do this? I have to think this is relatively simple no? I searched forums but i found no answer and I looked at how to theme a block but it doesnt say anything about takings omething out.

Comments

agentrickard’s picture

I believe you are referring to the bulleted list of menu items in the default Navigation block. To fix that, see:

Using Theme Override Functions
- http://drupal.org/node/11811 (which has a tutorial on this issue)

theme_menu_item()
- http://api.drupal.org/api/HEAD/function/theme_menu_item

If you are not referring to menu items, read http://drupal.org/node/11813 to learn how to edit "block.tpl.php"

--
http://ken.blufftontoday.com/
http://new.savannahnow.com/user/2
Search first, ask good questions later.

styro’s picture

Change the CSS in your theme.

You could leave the lists in the HTML, but configure you CSS to not put bullet point on the list items. I think (haven't looked it up) list-style-image: none; or list-style-type: none; should do it for most themes. And I think for Garland they actualy come from background images, so you'd need something like background-image: none;.

--
Anton
New to Drupal? | Troubleshooting FAQ
Example knowledge base built with Drupal

macm’s picture

CSS is the best choice easy and fast, but you can do with JQuery too, but first follow styro recommendation.

JQuery it is amazing tool and now are in Drupal core.

Cheers

agentrickard’s picture

Yup. CSS is probably the right answer. Quick and simple.

--
http://ken.blufftontoday.com/
http://new.savannahnow.com/user/2
Search first, ask good questions later.

netentropy’s picture

was this ever answered because I can't get it to cut off with CSS

vm’s picture

what theme in use?
what css have you tried?
have you tried the theme override mentioned in 1st comment?

is css aggregation on?
if yes, turn it off, before manipulating .css

a little help here beyond 10-12 words would be nice.
_____________________________________________________________________
Confucius says:
"Those who seek drupal answers should use drupal search!" : )

summit’s picture

Hi,
I still have this problem using Garland. The bullets are still shown on IE6.
I don't want to loose my bullets everywhere, only in this specific case where class is "no-bullets".
I tried handling this by giving my code the ul class "no-bullets". And using the following css in my style.css

ul.no-bullets {
  list-style-type: none;
  background-image: none;
}

But it is not working. Background-image: none; because in Garland the bullets are background-pictures.
Is this correct css code?
In my sourcecode of the page I see the following:

<div class="content"><div class="item-list"><ul class="no-bullets"><li>

Please advice?
What is css aggregation?
Thanks in advance!
Greetings,
Martijn

quicksand’s picture

You can also modify "system.css" on "system" core module.

Here are the lines to modify :

li.expanded {
  list-style-type: circle;
  list-style-image: url(../../misc/menu-expanded.png);
  padding: 0.2em 0.5em 0 0;
  margin: 0;
}
li.collapsed {
  list-style-type: disc;
  list-style-image: url(../../misc/menu-collapsed.png);
  padding: 0.2em 0.5em 0 0;
  margin: 0;
}
li.leaf {
  list-style-type: square;
  list-style-image: url(../../misc/menu-leaf.png);
  padding: 0.2em 0.5em 0 0;
  margin: 0;
}
Cyclist72’s picture

This might work:

ul.no-bullets {
  list-style-type: none;
  list-style-image: none;
}
quicksand’s picture

Also this :

#yourblock ul li { 
          list-style: none!important;
          list-style-image:none!important;
}
 
medenfield’s picture

Thanks