-
Notifications
You must be signed in to change notification settings - Fork 0
/
archive.php
38 lines (33 loc) · 829 Bytes
/
archive.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
<?php
get_header()
?>
<?php
if (has_post_thumbnail()) {
$post_thumbnail_id = get_post_thumbnail_id($post);
$featured_image = wp_get_attachment_image_src($post_thumbnail_id, 'full');
}
?>
<section class="hero"
style="background: url('<?php echo $featured_image[0]; ?>') no-repeat center center fixed; background-size:cover;">
<div class="hero-content">
<h1>
Il blog di Pomelia
</h1>
<p>
Natura, turismo, sostenibilità e dintorni: tutti i nostri articoli
</p>
</div>
</section>
<section class="page-post">
<?php
if (have_posts()) {
while (have_posts()) {
the_post();
get_template_part('template-parts/content', 'archive'); //file path, type ->
}
}
?>
</section>
<?php
get_footer();
?>