-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathloop.php
81 lines (69 loc) · 3.63 KB
/
loop.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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
<div id="main" role="main" class="twelvecol last">
<?php $the_query = new WP_Query( 'posts_per_page = -1' ); ?>
<?php if ( ! have_posts() ) : ?>
<div id="post-0" class="post error404 not-found">
<h1 class="entry-title"><?php _e( 'Not Found', 'brunelleschi' ); ?></h1>
<div class="entry-content">
<p><?php _e( 'Apologies, but no results were found for the requested archive. Perhaps searching will help find a related post.', 'brunelleschi' ); ?></p>
<?php get_search_form(); ?>
</div><!-- .entry-content -->
</div><!-- #post-0 -->
<?php endif; ?>
<?php while ( $the_query->have_posts() ) : $the_query->the_post(); ?>
<?php if ( ( function_exists( 'get_post_format' ) && 'gallery' == get_post_format( $post->ID ) ) || in_category( _x( 'gallery', 'gallery category slug', 'brunelleschi' ) ) ) : ?>
<article id="post-<?php the_ID(); ?>" <?php post_class('isotopeItem'); ?>>
<a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s'), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark">
<div class="galleryFrame">
<?php echo get_the_post_thumbnail($post->ID, 'medium'); ?>
</div>
</a>
<header>
<h2 class="entry-title"><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s'), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h2>
<div class="entry-meta">
<time datetime="<?php the_time('Y-m-d')?>"><?php the_time('M Y') ?></time>
</div>
<!--<div class="entry-content">
<?php the_excerpt(); ?>
</div>-->
</header>
</article><!-- #post-## -->
<?php elseif ( ( function_exists( 'get_post_format' ) && 'aside' == get_post_format( $post->ID ) ) || in_category( _x( 'asides', 'asides category slug', 'brunelleschi' ) ) ) : ?>
<article id="post-<?php the_ID(); ?>" <?php post_class('aside isotopeItem'); ?>>
<h1 class="entry-title">
<?php the_title(); ?>
</h1>
<section class="eightcol">
<div class="entry-content">
<?php the_content(); ?>
</div>
</section>
<section class="aboutMe fourcol last">
<?php $recent = new WP_Query( 'pagename=about-me' ); while($recent->have_posts()) : $recent->the_post();?>
<h3><?php the_title(); ?></h3>
<?php the_content(); ?>
<?php endwhile; ?>
</section>
</article>
<?php else : ?>
<article id="post-<?php the_ID(); ?>" <?php post_class('isotopeItem'); ?>>
<header>
<h2 class="entry-title"><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'brunelleschi' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h2>
<div class="entry-meta">
<time datetime="<?php the_time('Y-m-d')?>"><?php the_time('M Y') ?></time>
</div><!-- .entry-meta -->
</header>
<div class="entry-content">
<?php the_excerpt(); ?>
</div><!-- .entry-content -->
</article><!-- #post-## -->
<?php comments_template( '', true ); ?>
<?php endif; ?>
<?php endwhile; ?>
<?php wp_reset_postdata(); ?>
</div>
<?php if ( $wp_query->max_num_pages > 1 ) : ?>
<nav id="nav-below" class="navigation">
<div class="nav-previous"><?php next_posts_link( __( '<span class="meta-nav">←</span> Older posts', 'brunelleschi' ) ); ?></div>
<div class="nav-next"><?php previous_posts_link( __( 'Newer posts <span class="meta-nav">→</span>', 'brunelleschi' ) ); ?></div>
</nav><!-- #nav-below -->
<?php endif; ?>