Hallo,
ich möchte auf einer Seite nach einem Einleitungstext alle Artikel aus dem Jahr 2010 ausgeben.
Ich habe bereits ein neues Template dafür angelegt, aber komme nicht so recht weiter.
Mit folgendem Code versuche ich die Artikel auszugeben (das Jahr 2010 wird hier noch nicht berücksichtigt)
PHP
<?php if (have_posts()) : ?>
<?php while (have_posts()) : the_post(); ?>
<?php if (is_last_post()) {?>
<div class="post-last" id="post-<?php the_ID(); ?>">
<?php } else { ?>
<div class="post" id="post-<?php the_ID(); ?>">
<?php } ?>
<h2>
<a href="<?php the_permalink() ?>" rel="bookmark" title="<?php printf(__ ('Permanent Link to %s', 'atahualpa'), get_the_title())?>"><?php the_title(); ?></a>
</h2>
<div style="clear: left;"></div>
<div class="entry">
<?php if ($ata_excerpts_home == "Full Posts") {
the_content(__('Mehr »', 'atahualpa')); } else {
the_excerpt(); }
?>
<p class="postmetadata">
<?php the_time('j. F Y') ?>
</p>
</div>
</div>
<?php endwhile; ?>
<?php if(function_exists('wp_pagenavi')) { ?>
<div class="wp-pagenavi-navigation">
<?php wp_pagenavi(); ?>
</div>
<?php } else { ?>
<div class="navigation">
<div class="older"><?php next_posts_link(__('« Ältere Meldungen', 'atahualpa')); ?></div>
<div class="newer"><?php previous_posts_link(__('Neuere Meldungen »', 'atahualpa')); ?></div>
<div style="clear:both"></div>
</div>
<?php } ?>
<?php else : ?>
<h2 class="center"><?php _e('Not Found', 'atahualpa'); ?></h2>
<p class="center"><?php _e('Sorry, but you are looking for something that is not here.', 'atahualpa'); ?></p>
<?php include (TEMPLATEPATH . "/searchform.php"); ?>
<?php endif; ?>
Alles anzeigen
Leider wird einzig und allein der Titel der Seite und das Datum der Seite ausgegeben.
Wie also bekomme ich die Verknüpfung hin auf einer Seite auch Artikel auszugeben?
Danke und viele Grüße.