• Не могу убрать поля в шапке сайта, загружал различные шапки с разным разрешением, но в любом случае были отступы. Скажите, что нужно поменять в CSS, чтобы убрать их http://news-cyber.ru.

    /* Site header */

    .main-title {
    margin: 0;
    font-size: 50px;
    line-height: 1.2em;
    }
    .site-logo {
    display: inline-block;
    *display: inline;
    *zoom: 1;
    max-width: 100%;
    }
    .site-description {
    margin: 0;
    }
    .inside-header {
    padding: 40px;
    }
    .header-widget {
    float: right;
    overflow: hidden;
    max-width: 50%;
    }
    .header-widget .widget {
    padding: 0 0 20px;
    margin-bottom: 0;
    }
    .header-widget .widget:last-child {
    padding-bottom:0;
    }
    .nav-float-right .header-widget .widget {
    padding: 0 0 10px;
    }
    .nav-float-right .header-widget .widget:last-child {
    padding-bottom: 0;
    }
    .nav-float-right .header-widget {
    position:relative;
    top: -10px;
    }

    .post-image {
    margin: 2em 0 0;
    }

    /* Page Header Add-on */
    .page-header-image,
    .page-header-image-single {
    line-height: 0; /* no more weird spacing */
    }

    .separate-containers .page-header-image,
    .separate-containers .page-header-content {
    margin-top: 30px;
    }

    .inside-page-header {
    padding: 40px;
    }

    .separate-containers .page-header-image-single,
    .separate-containers .page-header-content-single {
    margin-top: 30px;
    }

    .separate-containers .inside-article .page-header-image-single,
    .separate-containers .inside-article .page-header-content-single,
    .one-container .inside-article .page-header-image-single,
    .one-container .inside-article .page-header-content-single,
    .separate-containers .inside-article .page-header-image,
    .separate-containers .inside-article .page-header-content,
    .one-container .inside-article .page-header-image,
    .one-container .inside-article .page-header-content {
    margin-bottom: 2em;
    margin-top: 0;
    }

Просмотр 5 ответов — с 1 по 5 (всего 5)
  • Дело в том, что в хидере (56 строка html http://prntscr.com/980jai ) у вас генерится код:

    .inside-header {padding-top: 40px; padding-right: 40px; padding-bottom: 40px; padding-left: 40px; }

    То ли он ручками прописан, то ли генерируется темой — не важно. Смысл в том, что подгружается он после style.css (50-я строка).
    Т.е все ваши изменения в style.css относительно падингов в .inside-header бесполезны.
    Гляньте код хидера, может нужно просто подправить там…

    Евгений я посмотрел код php не могу найти там размеры чтобы обнулить, с php пока незнаком, там видимо что — то другое нужно поправить, посмотрите пожалуйста

    <?php
    /**
    * The Header for our theme.
    *
    * Displays all of the <head> section and everything up till <main id=»main»>
    *
    * @package GeneratePress
    */
    ?><!DOCTYPE html>
    <html <?php language_attributes(); ?>>
    <head>
    <meta charset=»<?php bloginfo( ‘charset’ ); ?>»>
    <meta http-equiv=»X-UA-Compatible» content=»IE=edge» />
    <link rel=»profile» href=»http://gmpg.org/xfn/11″&gt;
    <link rel=»pingback» href=»<?php bloginfo( ‘pingback_url’ ); ?>»>
    <?php wp_head(); ?>
    </head>

    <body <?php generate_body_schema();?> <?php body_class(); ?>>
    <?php do_action( ‘generate_before_header’ ); ?>
    «><?php _e( ‘Skip to content’, ‘generate’ ); ?>
    <header itemtype=»http://schema.org/WPHeader&#187; itemscope=»itemscope» id=»masthead» <?php generate_header_class(); ?>>
    <div <?php generate_inside_header_class(); ?>>
    <?php do_action( ‘generate_before_header_content’); ?>
    <?php generate_header_items(); ?>
    <?php do_action( ‘generate_after_header_content’); ?>
    </div><!— .inside-header —>
    </header><!— #masthead —>
    <?php do_action( ‘generate_after_header’ ); ?>

    <div id=»page» class=»hfeed site grid-container container grid-parent»>
    <div id=»content» class=»site-content»>
    <?php do_action(‘generate_inside_container’); ?>

    В style.css в конец добавь:

    header .inside-header {
    	padding: 0px;
    }

    Получится что-то типа такого: http://prntscr.com/989u28
    ЗЫ. Что-то форум подтупливает. Приходится по 2 3 раза сообщение писать… 🙂 Главное чтобы потом всё это «полотенце» не проявилось.

    Модератор Yui

    (@fierevere)

    永子

    Приходится по 2 3 раза сообщение писать

    не надо по нескольку раз ) акисмет это дурит, причем не только на ваши сообщения

    А все хорошо, Евгений СПАСИБО БОЛЬШОЕ!

Просмотр 5 ответов — с 1 по 5 (всего 5)
  • Тема «Помогите убрать поля в шапке» закрыта для новых ответов.