So that code works for the_excerpt but not for the_content? I have to ask: have you typed something into the “Post” box for your entries? I’m thinking that maybe you’ve only written something in the “Optional Excerpt” box.
And where’s the first part of your loop, this bit:
<?php if (have_posts()) : while (have_posts()) : the_post();
Should your first line look like this:
<?php if (have_posts()) : query_posts($query_string . '&category_name=features'); while (have_posts()) : the_post();
That’s similar to what I do to exclude a certain category from my main loop.
I have posts content – remember, this isn’t the ‘Single post’ page I’m editing but the main site front page.
Your code doesn’t help…yet. When I use it I get the error ‘Parse error: parse error, unexpected $ in /…/wp-content/themes/fast-lane/features.php on line 14’
Where the file in question contains the following code:
<?php if (have_posts()) : query_posts($query_string . '&category_name=features'); while (have_posts()) : the_post(); ?>
<table border="0" width="100%">
<tr>
<td><h9>" title="<?php the_time('l j F Y H:i') ?>"><?php the_title() ?></h9></td>
</tr>
<tr>
<td align="justify"><div class="entry">
<?php the_content(); ?>
</div></td>
</tr>
</table>
(It is such a small file as it is included in the main page using a php_include)
I have tried putting <?php endif; ?> on the end but this also doesn’t work.
??!??!??
Yeah, main page, got it. That’s the code from my main page. What’s the code for feature.php and the code for index.php? I think, since you’re dealing with a combo of those two pages, we need to see all the code.
Something’s happening to your code as you paste it here (one of the frustrations of this forum). I don’t think all of it is coming through. Try posting the main index page and that feature page as text files somewhere (or just change the extensions to “phps”) so we can look at it. Another option is to use a pastebin, something this forum should really have built into it.
Also, what if you use another template? Does the_content display? If so, you know you’ve got a template issue. If not, you know you have a database issue. Try another template and see what happens to your content.