add blocks cache
This commit is contained in:
@@ -10,9 +10,9 @@ $curr_post = get_post( $id );?>
|
|||||||
<?if ( has_post_thumbnail($curr_post->ID) ) :?>
|
<?if ( has_post_thumbnail($curr_post->ID) ) :?>
|
||||||
<div class="mini-card-img">
|
<div class="mini-card-img">
|
||||||
<a href="<?the_permalink($curr_post->ID);?>"><img class="mini-card-img" src="<?php echo get_the_post_thumbnail_url($curr_post->ID); ?>" alt="<?=$curr_post->post_title;?>">
|
<a href="<?the_permalink($curr_post->ID);?>"><img class="mini-card-img" src="<?php echo get_the_post_thumbnail_url($curr_post->ID); ?>" alt="<?=$curr_post->post_title;?>">
|
||||||
<?if( has_tag( 'видео' ) ):?>
|
<?//if( has_tag( 'видео' ) ):
|
||||||
<span class="play-card"></span>
|
// echo '<span class="play-card"></span>';
|
||||||
<?endif?>
|
//endif?>
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
<?endif?>
|
<?endif?>
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
# три последних эвента
|
# три последних эвента
|
||||||
|
|
||||||
$posts = get_posts( array(
|
$zakon_posts = get_posts( array(
|
||||||
'numberposts' => 2,
|
'numberposts' => 2,
|
||||||
'category' => 6,
|
'category' => 6,
|
||||||
'post_type' => 'post',
|
'post_type' => 'post',
|
||||||
@@ -11,24 +11,22 @@ $posts = get_posts( array(
|
|||||||
) );
|
) );
|
||||||
|
|
||||||
# вывод поста
|
# вывод поста
|
||||||
if( $posts ):?>
|
if( $zakon_posts ):?>
|
||||||
|
|
||||||
<div class="publs_right">
|
<div class="publs_right">
|
||||||
|
|
||||||
<div class="publs_right_title">Законодательство</div>
|
<div class="publs_right_title">Законодательство</div>
|
||||||
|
|
||||||
<?foreach($posts as $post):
|
<?foreach($zakon_posts as $zakon):
|
||||||
setup_postdata( $post );
|
//setup_postdata( $post );
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<div class="publs_right_item">
|
<div class="publs_right_item">
|
||||||
<a href="<?php the_permalink(); ?>"><?php the_title();?></a>
|
<a href="<?=get_permalink($zakon);?>"><?php echo $zakon->post_title;?></a>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<?php endforeach;?>
|
<?php endforeach;?>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<?wp_reset_postdata();
|
<?endif;?>
|
||||||
|
|
||||||
endif;
|
|
||||||
50
footer.php
50
footer.php
@@ -10,12 +10,22 @@
|
|||||||
|
|
||||||
|
|
||||||
<?php // include VIJ_CACHE.'leftmenu.html';?>
|
<?php // include VIJ_CACHE.'leftmenu.html';?>
|
||||||
<?php get_template_part( '/blocks/leftmenu');?>
|
<?php if (LANG_VERSION == 'en'){
|
||||||
|
get_blocks_gen( 'left_menu_en' );
|
||||||
|
} else {
|
||||||
|
get_blocks_gen( 'left_menu' );
|
||||||
|
}
|
||||||
|
//get_template_part( '/blocks/leftmenu');?>
|
||||||
|
|
||||||
<?if (LANG_VERSION == 'ru'):?>
|
<?if (LANG_VERSION == 'ru'):?>
|
||||||
|
|
||||||
<?php get_template_part( '/blocks/opinion', null, ['subclass' => '']);?>
|
<?php // get_template_part( '/blocks/opinion', null, ['subclass' => '']);
|
||||||
<?php get_template_part( '/blocks/citats')?>
|
get_blocks_gen('opinion');
|
||||||
|
?>
|
||||||
|
|
||||||
|
<?php // get_template_part( '/blocks/citats');
|
||||||
|
get_blocks_gen( 'citats' );?>
|
||||||
|
|
||||||
<?php //include VIJ_CACHE.'opinion.html';?>
|
<?php //include VIJ_CACHE.'opinion.html';?>
|
||||||
<?php //get_template_part( '/blocks/citata', null, ['subclass' => '']);?>
|
<?php //get_template_part( '/blocks/citata', null, ['subclass' => '']);?>
|
||||||
<?php get_template_part( '/blocks/events');?>
|
<?php get_template_part( '/blocks/events');?>
|
||||||
@@ -71,35 +81,20 @@
|
|||||||
<?if (LANG_VERSION == 'ru'):?>
|
<?if (LANG_VERSION == 'ru'):?>
|
||||||
|
|
||||||
<div class="right-info">
|
<div class="right-info">
|
||||||
<a href="https://vetandlife.ru/parthers/ispytatelnyj-centr-fgbu-vgnki-provodit-razlichnye-vidy-issledovanij-po-vyyavleniju-falsifikacii-molochnoj-produkcii?erid=LatgBbd7S">
|
<? banners_conf_display( 'vgnki_240x400' ) ?>
|
||||||
<img src="https://vetandlife.ru/wp-content/uploads/2023/05/vgnki_240x400_may23.jpg" width="240" height="400" />
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="right-info">
|
|
||||||
<a href="https://roskachestvo.gov.ru/organic/contest/?erid=LatgBhSgx" target="_blank">
|
|
||||||
<img src="https://vetandlife.ru/wp-content/uploads/2023/01/rop.png" width="240" height="97" />
|
|
||||||
</a>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<?endif?>
|
<?endif?>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<?if (LANG_VERSION == 'en'){
|
<?if (LANG_VERSION == 'en'){
|
||||||
get_template_part( '/blocks/regulation');
|
get_template_part( '/blocks/regulation');
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
get_template_part( '/blocks/zakons');
|
// get_template_part( '/blocks/zakons');
|
||||||
}
|
get_blocks_gen( 'zakons' );
|
||||||
?>
|
}?>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<?php //include VIJ_CACHE.'zakons.html';?>
|
|
||||||
|
|
||||||
<?if (LANG_VERSION == 'en'):?>
|
<?if (LANG_VERSION == 'en'):?>
|
||||||
<?get_template_part( '/blocks/enmosts', null, ['subclass' => '']);?>
|
<?get_template_part( '/blocks/enmosts', null, ['subclass' => '']);?>
|
||||||
<?get_template_part( '/blocks/enmosts', null, ['subclass' => 'mob-lite']);?>
|
<?get_template_part( '/blocks/enmosts', null, ['subclass' => 'mob-lite']);?>
|
||||||
@@ -146,18 +141,9 @@
|
|||||||
|
|
||||||
|
|
||||||
<div class="mobile-info">
|
<div class="mobile-info">
|
||||||
<a href="https://vetandlife.ru/parthers/ispytatelnyj-centr-fgbu-vgnki-provodit-razlichnye-vidy-issledovanij-po-vyyavleniju-falsifikacii-molochnoj-produkcii?erid=LatgBbd7S">
|
<? banners_conf_display( 'vgnki_240x200' ) ?>
|
||||||
<img src="https://vetandlife.ru/wp-content/uploads/2023/05/vgnki_240x200_may23.jpg" width="240" height="200" />
|
|
||||||
</a>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mobile-info">
|
|
||||||
<a href="https://roskachestvo.gov.ru/organic/contest/?erid=LatgBhSgx" target="_blank">
|
|
||||||
<img src="https://vetandlife.ru/wp-content/uploads/2023/01/rop.png" width="240" height="97" />
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<?endif?>
|
<?endif?>
|
||||||
|
|
||||||
|
|||||||
@@ -15,12 +15,12 @@ define('IMGSERVER', 'https://img.vetandlife.ru/');
|
|||||||
require ABSPATH.'/vendor/autoload.php';
|
require ABSPATH.'/vendor/autoload.php';
|
||||||
|
|
||||||
#отключаем автообновления
|
#отключаем автообновления
|
||||||
add_filter('pre_site_transient_update_core',create_function('$a', "return null;"));
|
//add_filter('pre_site_transient_update_core',create_function('$a', "return null;"));
|
||||||
wp_clear_scheduled_hook('wp_version_check');
|
//wp_clear_scheduled_hook('wp_version_check');
|
||||||
|
|
||||||
remove_action( 'load-update-core.php', 'wp_update_plugins' );
|
//remove_action( 'load-update-core.php', 'wp_update_plugins' );
|
||||||
add_filter( 'pre_site_transient_update_plugins', create_function( '$a', "return null;" ) );
|
//add_filter( 'pre_site_transient_update_plugins', create_function( '$a', "return null;" ) );
|
||||||
wp_clear_scheduled_hook( 'wp_update_plugins' );
|
//wp_clear_scheduled_hook( 'wp_update_plugins' );
|
||||||
|
|
||||||
|
|
||||||
#отключаем эмодзи
|
#отключаем эмодзи
|
||||||
|
|||||||
10
header.php
10
header.php
@@ -4,12 +4,13 @@
|
|||||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
|
||||||
<meta name="yandex-verification" content="22f98955910722f8" />
|
<meta name="yandex-verification" content="22f98955910722f8" />
|
||||||
|
<meta name="zen-verification" content="9Ui9YzVJgKUB7bIgRNnAZqdHCNI8v9REm3TDpW0kciEicYyuD640moNznBDbFqcT" />
|
||||||
<title><?php wp_title('|', true, 'right');?><?=get_bloginfo('name')?></title>
|
<title><?php wp_title('|', true, 'right');?><?=get_bloginfo('name')?></title>
|
||||||
|
|
||||||
<?if (defined('TESTMODE') and TESTMODE == 1):?>
|
<?if (defined('TESTMODE') and TESTMODE == 1):?>
|
||||||
<link rel="stylesheet" href="<?php echo get_template_directory_uri();?>/style-test.css?ver=3">
|
<link rel="stylesheet" href="<?php echo get_template_directory_uri();?>/style-test.css?ver=3">
|
||||||
<?else:?>
|
<?else:?>
|
||||||
<link rel="stylesheet" href="<?php echo get_stylesheet_uri();?>?ver=360">
|
<link rel="stylesheet" href="<?php echo get_stylesheet_uri();?>?ver=364">
|
||||||
<?endif?>
|
<?endif?>
|
||||||
<link href="https://use.fontawesome.com/releases/v5.0.13/css/all.css" rel="stylesheet">
|
<link href="https://use.fontawesome.com/releases/v5.0.13/css/all.css" rel="stylesheet">
|
||||||
<!--<link href="<?php echo get_stylesheet_directory_uri()?>/pub/fontawesome.css" rel="stylesheet">-->
|
<!--<link href="<?php echo get_stylesheet_directory_uri()?>/pub/fontawesome.css" rel="stylesheet">-->
|
||||||
@@ -103,17 +104,16 @@ screen.colorDepth:screen.pixelDepth))+";u"+escape(document.URL)+
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<?else:?>
|
<?else:?>
|
||||||
|
|
||||||
<div id="mainbanner">
|
<div id="mainbanner">
|
||||||
<a href=" https://vetandlife.ru/reklama-special?erid=LatgBVedN"><img src ="https://vetandlife.ru/wp-content/uploads/2022/04/2000x125_64c.gif?ver=2" /></a>
|
<? banners_conf_display( 'mainbanner' ) ?>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="mobmainbanner">
|
<div id="mobmainbanner">
|
||||||
<a href=" https://vetandlife.ru/reklama-special?erid=LatgBVedN"><img src =" https://vetandlife.ru/wp-content/uploads/2022/04/554x86.gif?ver=2" /></a>
|
<? banners_conf_display( 'mobmainbanner' ) ?>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<?endif?>
|
<?endif?>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -41,9 +41,13 @@ $nn = 0;?>
|
|||||||
|
|
||||||
<?$nn++?>
|
<?$nn++?>
|
||||||
|
|
||||||
<?//if ($nn == 5):
|
<?//if ($nn == 1):
|
||||||
// card_post_id(25830, '');
|
//card_post_id(28999, '');
|
||||||
// include get_template_directory().'/blocks/card_post_happy.php';
|
// include get_template_directory().'/blocks/card_post_happy.php';
|
||||||
|
//elseif($nn == 3):
|
||||||
|
//card_post_id(29001, '');
|
||||||
|
//elseif($nn == 4):
|
||||||
|
//card_post_id(29005, '');
|
||||||
//endif?>
|
//endif?>
|
||||||
|
|
||||||
<?if ($nn < 25):?>
|
<?if ($nn < 25):?>
|
||||||
|
|||||||
@@ -10,7 +10,8 @@ get_header();?>
|
|||||||
|
|
||||||
<?if (isset($_POST['email'])) {
|
<?if (isset($_POST['email'])) {
|
||||||
|
|
||||||
$email = trim($_POST['email']);
|
$email = strtolower(trim($_POST['email']));
|
||||||
|
|
||||||
|
|
||||||
if (filter_var($email, FILTER_VALIDATE_EMAIL)) {
|
if (filter_var($email, FILTER_VALIDATE_EMAIL)) {
|
||||||
|
|
||||||
|
|||||||
14
style.css
14
style.css
@@ -81,6 +81,7 @@ a{
|
|||||||
display: flex;
|
display: flex;
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
overflow-x: hidden;
|
||||||
font-family: 'GrtskPeta';
|
font-family: 'GrtskPeta';
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
@@ -589,14 +590,9 @@ a{
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
.orange_block a{
|
|
||||||
color: white !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.orange_button{
|
.orange_button{
|
||||||
|
|
||||||
background: orange;
|
background: orange;
|
||||||
@@ -619,6 +615,11 @@ a{
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.orange_block a{
|
||||||
|
color: white !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -1916,6 +1917,7 @@ a{
|
|||||||
.form-right input{
|
.form-right input{
|
||||||
width: 230px;
|
width: 230px;
|
||||||
height: 50px;
|
height: 50px;
|
||||||
|
font-size: 15px;
|
||||||
border-radius: 35px;
|
border-radius: 35px;
|
||||||
background: #F2F2F2;
|
background: #F2F2F2;
|
||||||
border: 1px solid #F2F2F2;
|
border: 1px solid #F2F2F2;
|
||||||
|
|||||||
Reference in New Issue
Block a user