Как это организовать?
Почему вместо archive-{post_type} работает single?
он должен быть как страницы
Q: How many images can I optimize for free?
A: In a default WordPress installation you can optimize around 100 images for free each month. WordPress creates different thumbnails of your images which all have to be compressed. Some plugins even add more sizes, so take a look at the Settings > Compress JPEG & PNG images page before you start optimization.
[_url]
уже пробовали указывать на вкладке "Письмо"?add_action( 'wp_ajax_favorites', 'favorites_function' );
add_action( 'wp_ajax_nopriv_favorites', 'favorites_function' );
function favorites_function() {
$post_id = $_POST['post_id'];
$favorites = array();
if ( isset( $_COOKIE['favorites'] ) ) {
$favorites = explode( ',', $_COOKIE['favorites'] );
}
$favorites[] = $post_id;
setcookie( 'favorites', implode( ',', $favorites ), time() + (DAY_IN_SECONDS * 5), '/' );
wp_die();
}
<?php if ( is_front_page() ) : ?>
<?php if ( has_nav_menu( 'header' ) ): ?>
<nav class="nav-container group" id="nav-header">
<div class="nav-toggle"><i class="fa fa-bars"></i></div>
<div class="nav-text"><!-- put your mobile menu text here --></div>
<div class="nav-wrap container"><?php wp_nav_menu( array('theme_location' => 'header', 'menu_class' => 'nav group', 'container' => '', 'menu_id' => '', 'fallback_cb' => false) ); ?></div>
</nav><!--/#nav-header-->
<?php endif; ?>
<?php if ( has_nav_menu( 'subheader' ) ): ?>
<nav class="nav-container group" id="nav-subheader">
<div class="nav-toggle"><i class="fa fa-bars"></i></div>
<div class="nav-text"><!-- put your mobile menu text here --></div>
<div class="nav-wrap container"><?php wp_nav_menu( array('theme_location' => 'subheader', 'menu_class' => 'nav group', 'container' => '', 'menu_id' => '', 'fallback_cb' => false) ); ?></div>
</nav><!--/#nav-subheader-->
<?php endif; ?>
<?php endif; ?>
add_
— remove_
add_action('customize_register','my_customize_register');
function my_customize_register( $wp_customize ) {
$wp_customize->add_panel();
$wp_customize->get_panel();
$wp_customize->remove_panel();
$wp_customize->add_section();
$wp_customize->get_section();
$wp_customize->remove_section();
$wp_customize->add_setting();
$wp_customize->get_setting();
$wp_customize->remove_setting();
$wp_customize->add_control();
$wp_customize->get_control();
$wp_customize->remove_control();
}
function remove_control( $wp_customize ) {
$wp_customize->remove_control( 'site_icon' );
}
add_action( 'customize_register', 'remove_control', 20, 1 );
wp_enqueue_script( 'script-name', get_stylesheet_directory_uri() . '/js/example.js', array(), '1.1' );