0
votes

I wish to use the Pinbin theme for my Wordpress blog only. I have created a custom theme for everything else, but for the blog, I would like to use this theme.

I took the main index php file from this template, along with the header and footer files. I renamed the header and footer files, and changed the header/footer calls to these files rather than the ones used by the rest of the site.

I assigned the theme to a page, but it's not showing any posts. The code is as follows:

<?php if (have_posts()) : ?>
<div id="post-area">
<?php while (have_posts()) : the_post(); ?> 
<div id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
<?php if ( has_post_thumbnail() ) { ?>
<div class="pinbin-image"><a href="<?php the_permalink() ?>"><?php the_post_thumbnail( 'summary-image' );  ?></a></div>
<div class="pinbin-category"><p><?php the_category(', ') ?></p></div>
<?php } ?>
<div class="pinbin-copy"><h2><a class="front-link" href="<?php the_permalink() ?>"><?php the_title(); ?></a></h2>
<p class="pinbin-date"><?php the_time(get_option('date_format')); ?>  </p>
<?php the_excerpt(); ?> 
<p class="pinbin-link"><a href="<?php the_permalink() ?>">&rarr;</a></p>
</div>
</div>       
<?php endwhile; ?>

Any ideas on why I'm not seeing anything?

Thanks, S

1

1 Answers

0
votes

The index.php file is used as a backup if there's no other template defined, you'll have to edit a different file if you want to edit a certain page type. See template hierarchy in the WordPress codex.

    +

You forgot an endif; at the bottom of your file.

Template hierachy WordPress