• Hi,

    I’m attempting to add some margin/padding on the top and bottom of the text. But even when I change to display:block, the margin only works horizontally. Currently I’m using line height to achieve the effect, but when the text is more than one line it doesn’t look pretty. Please help. Thank you.

    Here is my css.

    .advanced-sidebar-menu ul {
    display: block;
    }

    .advanced-sidebar-menu ul li {
    display: block;
    border-bottom: 1px solid;
    }

    .advanced-sidebar-menu li:last-child {
    border-bottom: none;
    }

    .advanced-sidebar-menu ul li a {
    font-size: 18px;
    line-height: 50px;
    }

    .advanced-sidebar-menu ul ul li {
    border: none;
    }

    .advanced-sidebar-menu ul ul li:before {
    content: “>”;
    padding-right: 8px;
    }

    .advanced-sidebar-menu ul ul li a {
    font-size: 16px;
    line-height: 16px;

    }

  • The topic ‘Margin or Padding’ is closed to new replies.