correct pinned post and add mail config
This commit is contained in:
@@ -1,14 +1,6 @@
|
||||
<?php
|
||||
// Получаем объект закрепленного поста из ACF поля 'pinned_post'
|
||||
//$pinned_post = get_field('pinned_post', 'options');
|
||||
|
||||
$sticky_posts = get_option('sticky_posts');
|
||||
|
||||
// Получаем последний идентификатор прилепленного поста
|
||||
$last_sticky_post_id = end($sticky_posts);
|
||||
|
||||
// Получаем объект поста по его идентификатору
|
||||
$pinned_post = get_post($last_sticky_post_id);
|
||||
$pinned_post = last_sticky_post();
|
||||
|
||||
|
||||
if ($pinned_post) :
|
||||
|
||||
Reference in New Issue
Block a user