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 trialSven Nuum
5,605 PointsWP Loop doesn't work as seen in video
I watched "The Wordpress Loop" video and followed every step, now 3 times already, but still after saving and refreshing links doesn't work and footer is missing and content is not visible..
This is the header.
Home Work Blog About Contact This is the page.php file.
Only thing I see is this, whatever page I click, although all the code should be ok? Im stuck here and dont get it whats the reason could be
<?php get_header(); ?>
<p>This is the front-page.php file.</p>
<?php if ( have_posts() ) : while ( have_posts() ) : the_posts(); ?>
<h3><?php the_title(); ?></h3>
<?php the_content(); ?>
<hr>
<?php endwhile; else: ?>
<p>There are no posts or pages here.</p>
<?php endif; ?>
<?php get_footer(); ?>
3 Answers
Sarah Armstrong
9,995 PointsTry changing the_posts(), at the end of the wile line, to the_post(), no 's'
Sven Nuum
5,605 PointsDidn't help...
Kevin Korte
28,149 PointsSince you are using front-page as your template, did you put the correct settings in the "Reading" tab of your WP admin dashboard? It appears you're trying to load the front-page.php file right? I'm a bit confused because of the formatting of your code. Are you sure WP isn't loading some page like index.php?