Hallo zusammen,
ich hab das gleiche Problem und möchte meine Kategorie ID: 6 ausblenden, nur dass bei mir im template der code:
[LEFT] [COLOR=#000000] [COLOR=#0000CC]<?php [/COLOR][COLOR=#006600]if ([/COLOR][COLOR=#0000CC]have_posts[/COLOR][COLOR=#006600]()) : while ([/COLOR][COLOR=#0000CC]have_posts[/COLOR][COLOR=#006600]()) : [/COLOR][COLOR=#0000CC]the_post[/COLOR][COLOR=#006600](); [/COLOR][COLOR=#0000CC]?>[/COLOR] [/COLOR] [/LEFT]
leider nicht vorhanden ist.
Mein Template holt sich die Startseite aus einer Datei blog.php die folgendermassen aussieht:
<div class="box">
<?php
include(TEMPLATEPATH . '/includes/version.php');
$the_query = new WP_Query('cat=-'. $ex_feat . ',-' . $ex_vid . '&showposts=' . $showposts . '&orderby=post_date&order=desc');
$counter = 0;
while ($the_query->have_posts()) : $the_query->the_post(); $do_not_duplicate = $post->ID;
?>
<?php $counter++; ?>
<div class="post-alt blog" <?php if ( ($counter == 4) ) { echo 'style="background:none !important;margin-bottom:0 !important;"'; ?><?php } ?>>
<?php if ( get_post_meta($post->ID, 'thumb', true) ) { ?> <!-- DISPLAYS THE IMAGE URL SPECIFIED IN THE CUSTOM FIELD -->
<img src="<?php echo get_post_meta($post->ID, "thumb", $single = true); ?>" alt="" class="th" />
<?php } else { ?> <!-- DISPLAY THE DEFAULT IMAGE, IF CUSTOM FIELD HAS NOT BEEN COMPLETED -->
<img src="<?php bloginfo('template_directory'); ?>/images/no-img-thumb.jpg" alt="" class="th" />
<?php } ?>
<h2><a title="Permanent Link to <?php the_title(); ?>" href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
<h3 class="post_date">Geschrieben am
<?php the_time('d F Y'); ?></h3>
<hr style="clear:both;" />
<div class="entry">
<?php echo strip_tags(get_the_excerpt(), '<a><strong>'); ?>
<p><span class="continue"><a title="Permanent Link to <?php the_title(); ?>" href="<?php the_permalink() ?>">Weiterlesen ...</a></span></p>
</div>
<h3 class="posted">Geschrieben in
<?php the_category(', ') ?><span class="comments"><?php comments_popup_link('Comments (0)', 'Comments (1)', 'Comments (%)'); ?></span></h3>
</div><!--/post-->
<?php endwhile; ?>
<div class="fix"></div>
<?php $archives_page = get_option('premiumnews_archives_page') . '/'; ?>
<p class="ar hl3"><a href="<?php echo "$archives_page"; ?>" class="more">Weiter FN Artikel in unserem Archiv ...</a></p>
</div>
Alles anzeigen
Könnte mir bitte jemand helfen, wie ich die ID 6 ausblenden kann. Mit meinen php Kenntnissen bekommen ich nur Fehlermeldungen :confused:
Vielen Dank