SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Wizard DoubleDee's Avatar
    Join Date
    Aug 2010
    Location
    Arizona
    Posts
    3,934
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)

    Can you margins on an <ul> ??

    Can you add margins to an Unordered List <ul> ??


    Debbie

  2. #2
    SQL Consultant gold trophysilver trophybronze trophy
    r937's Avatar
    Join Date
    Jul 2002
    Location
    Toronto, Canada
    Posts
    39,341
    Mentioned
    63 Post(s)
    Tagged
    3 Thread(s)
    yes, you can
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL
    "giving out my real stuffs"

  3. #3
    SitePoint Wizard DoubleDee's Avatar
    Join Date
    Aug 2010
    Location
    Arizona
    Posts
    3,934
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by r937 View Post
    yes, you can
    Had my style messed up.

    Thanks!


    Debbie

  4. #4
    It's all Geek to me silver trophybronze trophy
    ralph.m's Avatar
    Join Date
    Mar 2009
    Location
    Melbourne, AU
    Posts
    24,333
    Mentioned
    463 Post(s)
    Tagged
    8 Thread(s)
    Indeed, in most browsers an UL has margins by default, so you usually will need to modify them to avoid surprises.

  5. #5
    Non-Member bronze trophy
    Join Date
    Nov 2009
    Location
    Keene, NH
    Posts
    3,760
    Mentioned
    23 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by ralph.m View Post
    Indeed, in most browsers an UL has margins by default, so you usually will need to modify them to avoid surprises.
    Hence the use of resets; same for LI -- some browsers pad the ul, some margin the li, some pad the li... can drive you nutters.

    This comes up from time to time, and for some reason people have it in their head that tags like numbered headings, paragraphs and UL's can't accept certain values -- it's why you see this IDIOCY all the blasted time:

    Code:
    <div id="topNav">
      <ul id="topNavUL">
    usually applying things to the DIV that could just as easily be applied to the UL since from a CSS standpoint a display:block container is a display:block container, regardless of what tag it is. ALL CSS values are SUPPOSED to be applicable with the same result to ALL elements. (something Mozilla and Microsoft still can't wrap their heads around with their treatment of LEGEND, INPUT and TEXTAREA)


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •