1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

HELP: <ul> <li> Controlling using CSS

Discussion in 'HTML & Website Design' started by BuntaFujiwaraaa, Dec 4, 2012.

  1. #1
    Hi guys, how do I control li using CSS, does li have any properties?

    I want to make the space between each <li> smaller. How can i achieve that using CSS? What selectors should i use? ( i can't seem to find that anywhere )

    Example ->

    • Item 1
    • Item 2
    How do i narrow the gap between Item 1 and Item 2. (Meaning i want to push Item 2 up, nearer to Item 1)
     
    BuntaFujiwaraaa, Dec 4, 2012 IP
  2. abusschaert

    abusschaert Active Member

    Messages:
    265
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    65
    #2
    you need to target the <li> and ether try line height or the easy way by messing with padding-bottom:-2px;

    your CSS should look like this

    li {padding-bottom:-(pick a number 1 or 2 should be lots)px;}

    if you only want one list like this then you need to target that list by adding more detail
    ex.

    #(the div your list is in) UL IL { (Your CSS) }
     
    abusschaert, Dec 4, 2012 IP