Ansico-CPT-pagecontrol/ansico-ln-plugins/templates/archive-post-type.php

27 lines
881 B
PHP
Raw Normal View History

2026-04-17 20:10:27 +00:00
<?php
if (!defined('ABSPATH')) {
exit;
}
get_header();
$post_type = Ansico_LN_Plugins::get_current_archive_post_type();
$grouped_results = Ansico_LN_Plugins::get_archive_results_grouped_by_letter($post_type);
$title = Ansico_LN_Plugins::get_post_type_label($post_type);
?>
<main id="primary" class="site-main ansico-ln-archive-results" style="max-width: 960px; margin: 0 auto; padding: 2rem 1rem;">
<header class="page-header" style="margin-bottom: 2rem;">
<h1 class="page-title"><?php echo esc_html($title); ?></h1>
</header>
<?php if (!empty($grouped_results)) : ?>
<?php echo Ansico_LN_Plugins::render_alphabetical_archive_sections($grouped_results); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
<?php else : ?>
<p>Der blev ikke fundet nogen resultater.</p>
<?php endif; ?>
</main>
<?php
get_footer();