correct cookie footer

This commit is contained in:
2025-06-04 11:21:09 +03:00
parent b1697d2b5a
commit b6fdef315f
4 changed files with 12 additions and 14 deletions

View File

@@ -44,14 +44,16 @@ ini_set('display_errors','off');
use PHPMailer\PHPMailer\PHPMailer;
require_once 'vite.config.php';
//add jquery
function theme_enqueue_scripts() {
wp_enqueue_script('jquery');
}
add_action('wp_enqueue_scripts', 'theme_enqueue_scripts', 1);
require_once 'vite.config.php';
//setlocale(LC_ALL, 'ru_RU', 'ru_RU.UTF-8', 'ru', 'russian');
@@ -268,14 +270,6 @@ add_filter( 'single_template', function ( $single_template ) {
}, PHP_INT_MAX, 2 );
//куки
function add_cookie_consent() {
if (!isset($_COOKIE['cookie_consent_accepted'])) {
get_template_part('cookie-consent');
}
}
add_action('wp_footer', 'add_cookie_consent');
#search
function my_search_order( $query ) {