-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathindex.php
49 lines (46 loc) · 2.17 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 get_header(); ?>
<section class="news">
<h1 class="sr-only"><?php _e( "News", "commcitytheme" ); ?></h1>
<div class="container">
<?php
$sticky = get_option( 'sticky_posts' );
if ( !empty( $sticky ) ) :
$sticky_query = new WP_Query( 'p=' . $sticky[0] );
if ( $sticky_query->have_posts() ) : while ( $sticky_query->have_posts() ) : $sticky_query->the_post();
?>
<article id="post-<?php the_ID(); ?>" <?php post_class( 'news-feature' ); ?> itemscope itemtype="http://schema.org/BlogPosting">
<div class="row">
<h2 class="title text-center" itemprop="headline"><a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>"><?php the_title(); ?></a></h2>
</div>
<div class="row">
<div class="col-xs-7 excerpt" itemprop="articleBody">
<p><?php the_excerpt(); ?></p>
</div>
<div class="col-xs-5">
<figure class="thumb">
<a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>"><?php the_post_thumbnail( 'full', array( 'class' => 'img-responsive' ) ); ?></a>
</figure>
</div>
</div>
<?php the_tags( '<ul class="tags"><li>' . __( 'Tags', 'commcitytheme' ) . ':</li><li>', '</li><li>', '</li></ul>' ); ?>
</article>
<?php endwhile; endif; endif; wp_reset_postdata(); ?>
<?php if ( have_posts() ) : ?>
<div class="row">
<?php while ( have_posts() ) : the_post(); ?>
<div class="col-md-4">
<article id="post-<?php the_ID(); ?>" <?php post_class( 'article' ); ?> itemscope itemtype="http://schema.org/BlogPosting">
<figure class="thumb">
<a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>"><?php the_post_thumbnail( 'full', array( 'class' => 'img-responsive' ) ); ?></a>
</figure>
<h3 class="title" itemprop="headline"><a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>"><?php the_title(); ?></a></h3>
<span class="excerpt" itemprop="articleBody"><?php the_excerpt(); ?></span>
<?php the_tags( '<ul class="tags"><li>' . __( 'Tags', 'commcitytheme' ) . ':</li><li>', '</li><li>', '</li></ul>' ); ?>
</article>
</div>
<?php endwhile; ?>
</div>
<?php endif; ?>
</div>
</section>
<?php get_footer(); ?>