Answer the question
In order to leave comments, you need to log in
What is the best way to display news on the site through WordPress?
It is necessary to make sure that the site has a news page with a transition to the page of the corresponding news, it is also necessary that the last 3 news are displayed on the main page. Plus, there will still be a similar structure, only it will no longer be news, but other blocks.
How to do it? Through posts and rubrics? If so, how?
I also have the Advanced Custom Fields Pro plugin installed. Maybe through it is better somehow?
Answer the question
In order to leave comments, you need to log in
Through posts and rubrics?
// регистрируем тип записей Вакансии
function register_vacancy_entities() {
$vacancy_args = array(
'public' => true,
'label' => null,
'labels' => array(
'name' => 'Вакансии',
'singular_name' => 'Вакансия',
'add_new' => 'Добавить вакансию',
'add_new_item' => 'Добавление вакансии',
'edit_item' => 'Редактирование вакансии',
'new_item' => 'Новая вакансия',
'view_item' => 'Смотреть страницу вакансии',
'search_items' => 'Искать вакансии',
'not_found' => 'Не найдено',
'not_found_in_trash' => 'Не найдено в корзине',
'parent_item_colon' => '',
'menu_name' => 'Вакансии',
),
'menu_position' => 5,
'menu_icon' => 'dashicons-admin-users',
'rewrite' => array( 'slug' => 'vacancy' ),
'has_archive' => true
);
register_post_type( 'vacancy', $vacancy_args );
}
add_action( 'init', 'register_vacancy_entities' );
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question