SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Zealot frosco's Avatar
    Join Date
    Jul 2003
    Location
    WA state
    Posts
    136
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Hidden text leaves empty space -- how to hide?

    http://stylishmomandtot.com/

    On the left-hand menu there are menu items that are class "endcatcolor" -- I want to hide these items. I've tried visibility: hidden and display: none but it leaves an empty space.

    The menu is generated from a php include file -- I don't want to change it because it's skinned with templates, I want the end user to be able to change templates and have the ability to see that class down the line. I'd just like to add to the current css if that's possible??

    Thanks so much!

  2. #2
    Follow Me On Twitter: @djg gold trophysilver trophybronze trophy Dan Grossman's Avatar
    Join Date
    Aug 2000
    Location
    Philadephia, PA
    Posts
    20,580
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    The display:none links aren't leaving a space, it's the <br /> following them

    One answer is to not write out a bunch of links and line breaks. Put them in an unordered list, for example, and set display:none on the entire <li> item containing the menu item you want to hide. Then there will be no space.

  3. #3
    om nom nom nom Stomme poes's Avatar
    Join Date
    Aug 2007
    Location
    Netherlands
    Posts
    10,233
    Mentioned
    47 Post(s)
    Tagged
    1 Thread(s)
    Be careful with display: none for any public site geared to everyone. Screen readers unfortunately obey display: none and will not read those items out. If mouse clicks or javascript is required to get the links to display, then those folks are at some disadvantage.

    (if however going to another page has PHP change the settings or something, then you're prolly ok)


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
  •