File: /home/reachcon/public_html/wp-content/themes/reach-connects/index.php
<?php
// THIS FILE HANDLES THE LISTING OF YOUR BLOG ARGICLES.
// THIS PAGE ALSO USES THE DEFAULT SIDEBAR
// THIS FILE WILL ALSO BE USED IT A home.php FILE DOES NOT EXIST
global $omada,$omadaLayout;
get_header();
?>
<div class="dBlue"><h1>Blog</h1></div>
<div class="grid-x align-center">
<div class="large-10 cell">
<div class="spc"></div>
<main class="grid-container osection">
<div class="grid-x grid-padding-x">
<div class="cell medium-9">
<?php
// INSERT CONTENT TO BE DISPLAYED ABOVE BLOG - THIS PULLS FROM THE PLOG PAGE
$page_for_posts = get_option( 'page_for_posts' );
$content=apply_filters('the_content', get_post_field('post_content', $page_for_posts));
echo $content;
if ( have_posts() ){
while ( have_posts() ){
the_post();
echo '<div id="post-'.get_the_ID().'" '. get_post_class().'>';
// Column 2
echo '<header><h2 class="post-heading"><a href="'.get_the_permalink(get_the_ID()).'" rel="bookmark">'.get_the_title(get_the_ID()).'</a></h2></header>';
echo '<small>'.get_the_date( 'F j, Y' ).'</small>';
echo '<div class="post-content">';
$omadaLayout->customExcerpt(get_the_ID(),50,true,true);
if(get_the_category()){
echo '<small class="post-meta"><strong>Categories: </strong>'; the_category(', '); echo '</small>';
}
wp_link_pages( array( 'before' => '<div class="page-links">' . __( 'Pages:', 'omada' ), 'after' => '</div>' ) );
echo '</div>';
echo '<p class="text-right"><a href="'.get_the_permalink(get_the_ID()).'" class="button">Continue Reading</a></p>';
echo '</div>';
echo '<hr>';
}
$omadaLayout->paginationLinkNumbers();
}else{
echo '<article id="post-0" class="post no-results not-found">';
echo '<header><h1 class="post-heading">Nothing Found</h1></header>';
echo '<div class="post-content"><p>No results were found. Perhaps searching will help find a related post.</p>';
get_search_form();
echo '</div>';
echo '</article>';
}
?>
</div>
<div class="cell medium-3">
<?php dynamic_sidebar( 'defaultsidebar' ); ?>
</div>
</div>
</main>
</div>
</div>
<?php get_footer(); ?>