WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Exclude div from header.php (3 posts)

  1. kelleypb
    Member
    Posted 1 year ago #

    I would like to remove the div containing my header image from one page. I tried wrapping the following code around the div in question:

    <?php if( !is_page('directions') ) : ?>
    
    <?php endif; ?>

    But it still leaves the empty space. I need to add display: none so that the div disappears completely. I have searched everywhere but to no avail.

  2. kelleypb
    Member
    Posted 1 year ago #

    I also tried adding to the page `<style>
    .slogan
    {
    display: none !important;
    }
    </style>`

    But the empty space contain the .slogan div remains. There must be some CSS rule overriding my code.

  3. kelleypb
    Member
    Posted 1 year ago #

    There was a height designated in pixels preventing the collapse. All solved.

Topic Closed

This topic has been closed to new replies.

About this Topic