-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.php
53 lines (39 loc) · 1.32 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
50
51
52
53
<?php get_header(); ?>
<main id="content" class="blog">
<div class="magneti-custom-template-wrapper">
<?php
$blogPageId = get_option('page_for_posts');
$img = wp_get_attachment_image_src(get_post_thumbnail_id(get_option('page_for_posts')),'2048x2048');
$imageUrl = $img[0];
?>
<div class="custom-template-module gradient-green-to-navy template-part-hero has-bg dark-mode">
<div class="hero-img-container">
<div class="aspect-container" style="background-image: url(<?php echo $imageUrl; ?>); background-size: cover; background-position: center;">
<div class="center wide">
<div class="normal-hero-wrap">
<?php the_field('hero_content', $blogPageId); ?>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="center outer wide">
<div class="blog-posts-grid">
<?php while ( have_posts() ) : the_post(); ?>
<?php
get_template_part(
'template-parts/components/blog-post',
null, // name
[
'thePost' => $post
]
);
?>
<?php endwhile; ?>
</div>
<?php the_posts_pagination(['mid_size' => 5, 'prev_next' => false]); ?>
</div>
</main>
<?php //end content ?>
<?php get_footer(); ?>