Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

WordPress From Bootstrap to WordPress Create Bootstrap Styled Theme Templates Creating a Full Width Static Page Template

Content not appearing in container/ Full-Width Template

I have been unable to get my text in the wordpress body to appear. I've followed Zac's code and I don't know why mine is not showing up. It's in the container where he puts the 4 columns and lorem ipsum text. Here is my code

<?php
/*
  Template Name: Full Width Template
*/

?>

<?php get_header(); ?>

  <div class="container">
    <div class="row">

      <div class="col-md-12">

        <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>

          <div class="page-header">
            <h1><?php the_title(); ?></h1>
          </div>

        <?php endwhile; else: ?>

          <div class="page-header">
            <h1>Oh no!</h1>
          </div>

          <p>No Content is appearing for this page!</p>

        <?php endif; ?>

      </div>


    </div>

<?php get_footer(); ?>

1 Answer

If it's content you are needed to show, you need to use either function, the_content() or the_excerpt(). you only have the title.

That worked, thanks Jacob!

Not a problem.