Organising and inserting content
-
https://reviews.sekhu.net/
https://reviews.sekhu.net/category/filmIn the first link each box will contain an exercpt. This bit I understand – use the excerpt tag and place where needed, excluding the cats I don’t want and limiting it to one entry.
The second link is what will displayed when the user clicks on the excerpt.
In the first box in the second link I want to include the content up to the point where it says “more”. The second box will contain the previous entry in the same fashion.
When the user clicks either entry, it will display the full entry for that post. What tags, code do I need to make this work?
I’ve looked at other themes, and tried this:
<?php
if ($posts) {
foreach($posts as $post) { start_wp();
?>
<br />
<a class="title" href="<?php the_permalink() ?>" style="text-decoration:none;" rel="bookmark" title="Permanent Link: <?php the_title(); ?>"><?php the_title(); ?></a>
<div class="cite"><?php the_time("l F dS Y") ?>, <?php the_time() ?> <?php edit_post_link(); ?><br />
<?php _e("Filed under:"); ?> <?php the_category(',') ?></div><?php the_content(); ?>
But I got a load of php errors, and everytime I fixed it, it buggered up even more.
1) Could the content be displayed in single.php by just using
<?php the_content(); ?>
2) Would I do the same to display the content up to “more” on the second link?
Thanks in advance
- The topic ‘Organising and inserting content’ is closed to new replies.