Skip to content

Instantly share code, notes, and snippets.

@lumpysimon
Created March 6, 2012 22:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lumpysimon/1989492 to your computer and use it in GitHub Desktop.
Save lumpysimon/1989492 to your computer and use it in GitHub Desktop.
wordpress page.php
<?php
get_header();
if ( have_posts() ) {
while ( have_posts() ) {
the_post();
$title = the_title( '<h1>', '</h1>', false );
?>
<section class="wrap">
<div class="col col-primary">
<article>
<?php
if ( has_post_thumbnail() ) { ?>
<div class="big-pic">
<?php the_post_thumbnail( 'big-pic' ); ?>
<div class="big-pic-text">
<?php echo $title; ?>
</div>
</div>
<?php } else { ?>
<?php echo $title; ?>
<?php } ?>
<?php the_content();
?>
</article>
</div>
<div class="col col-secondary">
<p>Sidebar</p>
</div>
</section>
<?php
}
}
get_footer();
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment