This repository has been archived by the owner on Jan 31, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.php
49 lines (42 loc) · 1.47 KB
/
index.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
<?php
use CG\Templates\PostTile\PostTileTemplate;
get_header(); ?>
<div class="container">
<?php if (have_posts()) : ?>
<main style="display: flex; flex-direction: column; gap: 4rem">
<?php
while (have_posts()) :
the_post();
$post_tile = new PostTileTemplate();
$post_tile->render();
endwhile;
?>
</main>
<?php
$prev = get_previous_posts_link();
$next = get_next_posts_link();
$styles = $prev ? 'justify-content: space-between;' : 'justify-content: flex-end;';
?>
<div style="display: flex; <?= $styles ?>">
<?php
echo $prev;
echo $next;
?>
</div>
<?php else: ?>
<p>
<?= __('The given phrase', 'cg') ?>
- <em style="font-weight: bold"><?= get_search_query(false) ?></em> -
<?= __('has not been found.', 'cg') ?>
</p>
<p><?= __('Hints', 'cg') ?>:</p>
<ul>
<li><?= __('Check that all words are spelled correctly.', 'cg') ?>.</li>
<li><?= __('Please try different keywords.', 'cg') ?>.</li>
<li><?= __('Try using more general keywords.', 'cg') ?>.</li>
</ul>
<?php endif; ?>
</div>
<?php
get_sidebar();
get_footer();