diff --git a/blocks/golos.php b/blocks/golos.php index c1f801a..811cf2d 100644 --- a/blocks/golos.php +++ b/blocks/golos.php @@ -1,12 +1,12 @@ - +

- +
diff --git a/functions.php b/functions.php index 162df67..d2d0b10 100644 --- a/functions.php +++ b/functions.php @@ -5,8 +5,8 @@ use PHPMailer\PHPMailer\PHPMailer; //setlocale(LC_ALL, 'ru_RU', 'ru_RU.UTF-8', 'ru', 'russian'); define('IMGURL', 'http://img.vetandlife.ru/'); -define("COOK_GOLOS", "_ya_id_76543_w"); -define("COOK_VALUE", "7895"); +define("COOK_GOLOS", "_ya_id_76577_w"); +define("COOK_VALUE", "7896"); define('VIJ_CACHE', ABSPATH.'wp-content/themes/vij/cache/'); define('BASE_VIJ', ABSPATH.'wp-content/themes/vij/'); @@ -48,6 +48,11 @@ require get_template_directory().'/src/perevod.php'; require get_template_directory().'/lang.php'; require get_template_directory().'/blocks/card_post_id.php'; + + + + + //require ABSPATH.'vendor/masterforweb/db_lite/db_lite.php'; function vij_send_smtp_email( PHPMailer $phpmailer ) { @@ -129,6 +134,14 @@ add_filter('category_template', function (){ }); + + + + + + + + //свой шаблон для категории add_filter( 'single_template', function ( $single_template ) { @@ -646,9 +659,9 @@ add_action( 'init', function () { }, 0); */ - - + + add_action( 'pre_get_posts', function ($query) { if ( ! is_admin() && $query->is_main_query() && is_category() ) { @@ -671,6 +684,16 @@ add_action( 'pre_get_posts', function ($query) { }); +function print_menu_shortcode($atts=[], $content = null) { + $shortcode_atts = shortcode_atts([ 'name' => '', 'class' => '' ], $atts); + $name = $shortcode_atts['name']; + $class = $shortcode_atts['class']; + return wp_nav_menu( array( 'menu' => $name, 'menu_class' => $class, 'echo' => false ) ); +} + +add_shortcode('menu', 'print_menu_shortcode'); + + function add_text_to_the_feed_end( $content ){ $content .= '

diff --git a/header.php b/header.php index 309b800..13679f6 100644 --- a/header.php +++ b/header.php @@ -2,14 +2,15 @@ - + + <?php wp_title('|', true, 'right');?><?=get_bloginfo('name')?> - - + + @@ -62,14 +63,14 @@

- +
- +
diff --git a/index.php b/index.php index 9a60f04..d34b90c 100644 --- a/index.php +++ b/index.php @@ -40,14 +40,15 @@ $nn = 0;?> - +
- <?the_title();?> + + <?the_title();?> diff --git a/style.css b/style.css index a0363e1..ce41c60 100644 --- a/style.css +++ b/style.css @@ -500,6 +500,38 @@ a{ } + + + .orange_block a{ + color: white !important; + } + + .orange_button{ + + background: orange; + border-radius: 55px; + border: 1px solid orange; + color: white; + vertical-align: middle; + text-decoration: none; + text-transform: uppercase; + font-weight: bold; + font-size: 16px; + font-size: 11px; + line-height: 110%; + display: table-cell; + vertical-align: middle; + height: 45px; + padding-left: 22px; + padding-right: 22px; + + } + + + + + + .left_center_block{ margin-top: 8px; margin-bottom: 28px; @@ -603,11 +635,41 @@ a{ color: #F18129; } + +#content iframe{ + width: 100%; +} + +#content tr { + + border-top: 1px solid #E9EAEB; + border-bottom: 1px solid #E9EAEB; + +} + + #content td { + padding: 20px 0; + } + + #content h2, #content h3, #content h4{ + margin-top: 12px; + margin-bottom: 18px; + } + + +.fulltext{ + width: 100%; +} .fulltext a{ color: #2D9CDB; } + + .fulltext .current-menu-item a{ + color: black; + } + .fulltext > ul{ list-style: square outside; } @@ -636,6 +698,10 @@ a{ color: orange; } + .fulltext { + margin-right: 8px; + } + #fulltext img, .wp-block-image img { @@ -708,6 +774,51 @@ a{ } + + + .reklama_menu{ + + display: flex; + margin-left: 0; + margin-top: 22px; + margin-bottom: 22px; + font-size: 18px; + + } + + + .reklama_menu li{ + + font-weight: bold; + margin-right:15px; /*Добавляем отступ у пунктов меню*/ + } + + + + + .reklama_menu a:hover{ + color: #2D9CDB; + + } + + +.reklama_sub_h { + + font-size: 18px; + color: #171717; + text-align: center; + padding: 20px 10px 20px 20px; + margin-right: 4px; + background-color: #F2F2F2; + + +} + + + + + + .lmenu{ display: inline-block; vertical-align: middle; @@ -977,9 +1088,8 @@ a{ margin-bottom: 1em; /* Отступ снизу */ } - #content IMG{ - max-width: 100%; - + #content IMG{ + width: 100%; } #fulltext ul{ @@ -2134,6 +2244,30 @@ span.rub_back_title{ display: none; } + +#menu-reklama_menu{ + padding-bottom: 22px; +} + + +#menu-reklama_menu li a{ + color: black; + border: none; +} + + +#menu-reklama_menu li.current-menu-item{ + color: #2D9CDB; + border-bottom: 1px solid #2D9CDB; +} + +#menu-reklama_menu li.current-menu-item a{ + color: #2D9CDB; +} + + + + @media screen and ( max-width: 580px ) { #left{ @@ -2149,9 +2283,9 @@ span.rub_back_title{ margin: 0; } - #mainbanner { + /** #mainbanner { display: none; - } + } */ #header_icons{ margin-left: 0; @@ -2164,7 +2298,7 @@ span.rub_back_title{ #content{ - /*width: 100%;*/ + width: 100%; } @@ -2329,6 +2463,7 @@ span.rub_back_title{ body { width: 100%; margin-right: 8px; + overflow-x: hidden; } @@ -2457,19 +2592,63 @@ span.rub_back_title{ } + .menu-reklama_menu-container{ + display: inline-block; + margin: 0; + padding: 0; + margin-top: 22px; + margin-right: 22px; + overflow: hidden; + } +#menu-reklama_menu{ + margin: 0; + padding: 0; + +} + +.reklama_menu { + display: flex; + overflow-x: scroll; + -webkit-overflow-scrolling: touch; + +} + +.reklama_menu li{ + font-size: 13px; + margin-right: 12px; + padding-bottom: 12px; +} + +.reklama_menu li a{ + color: #909294; + } + + .reklama_menu li a:hover{ + color: #F18129; + } + + + +.reklama_menu li.current-menu-item{ + color: #171717; + font-weight: bold; + border-bottom: 3px solid #F18129; +} + + +.mini-card-img{ + max-width: 100%; + overflow-x: hidden; + overflow-y: hidden; + +} + } -@media (max-width: 599px){ - - .wp-block-columns { - - } - -} /** mobile **/ @media only screen @@ -2478,6 +2657,11 @@ and (max-device-width : 667px) { + #main{ + width: 100%; + } + + h1 { font-size: 24px; } @@ -2497,9 +2681,9 @@ and (max-device-width : 667px) { display: block; } - #mainbanner { + /**#mainbanner { display: none; - } + }*/ .mini-card{ width: 100%; @@ -2507,7 +2691,9 @@ and (max-device-width : 667px) { } .mini-card-img{ - width: 100%; + max-width: 100%; + overflow-x: hidden; + overflow-y: hidden; } #footer-contact{ @@ -2576,8 +2762,53 @@ and (max-device-width : 667px) { display: none; } - + + .menu-reklama_menu-container{ + display: inline-block; + margin: 0; + padding: 0; + margin-top: 22px; + margin-right: 22px; + overflow: hidden; + } + + + #menu-reklama_menu{ + margin: 0; + padding: 0; + margin-bottom: 22px; + } + + .reklama_menu { + display: flex; + overflow-x: scroll; + -webkit-overflow-scrolling: touch; + + } + + .reklama_menu li{ + font-size: 13px; + color: #909294; + margin-right: 12px; + padding-bottom: 12px; + } + + .reklama_menu li a{ + color: #909294; + } + + .reklama_menu li a:hover{ + color: #F18129; + } + + + + .reklama_menu li.current-menu-item{ + color: #171717; + font-weight: bold; + border-bottom: 3px solid #F18129; + }