Search code examples
cssdrupal-7borderclearfix

Remove gray line in clearfix from <div class="wrap clearfix"> Drupal 7


I would like to remove the gray line caused by the clearfix elements in my D7 theme (MD Photo). In particular, the div class="wrap clearfix" element, which has an unnecessary gray line at the bottom of the body elements.

I have tried quite a few fixes, but they haven't given me any results. Here's the list, so far

.clearfix:after {content:' ';}
.wrap: {border: none;}
.clearfix {border:none;}

And a host of other, similar border and content remover ideas.

Can anyone point me in the right direction?


Solution

  • After taking a look at Drupal 7, it seems as though this line you are referring to is added by the following:

    .pager a, .view-latest-from-blog li, .comment, .tabs ul.primary,
    .tabs ul.primary li a, .tabs ul.primary li.active a, .tabs ul.primary li a:hover,
    .meta-share-wrap, .meta_share, #footer {
        border-color: #e4e4e4;
    }
    

    In your case, it's being applied to the #footer element, therefore you would either remove the #footer selector from the initial declaration, or you would use the following to overwrite it:

    #main-content #footer {
        border: none;
    }