Hallo zusammen,
ich habe auf meiner Seite die Pagination-Funktion am Ende der Indexpage eingebunden. Mein Layout für die Artikelausgabe ist zweispaltig aufgeteilt. Sobald ich jedoch die nächste Seite meiner Artikel auswähle ändert sich das Layout auf eine Spalte. Ich habe bestimmt einen Code-Fehler, jedoch weiß ich nicht wo ich suchen soll.
Anbei der aktuelle Code der Indexpage:
PHP
<?php get_header(); ?>
<?php
/*
*Template Name: Index Page
*/
global $woo_options;
if (is_paged()) $is_paged = true; else $is_paged = '';
$counter = 0; $postcount = 0;
?>
<div id="main">
<div><?php echo do_shortcode( '[advps-slideshow optset="3"]' ); ?></div>
<br>
<?php
if ( get_query_var('paged') ) { $paged = get_query_var('paged'); }
elseif ( get_query_var('page') ) { $paged = get_query_var('page'); }
else { $paged = 1; }
query_posts('category_name=Kategorien&posts_per_page=10&paged=' . $paged);
?>
<?php if (have_posts()) : $count = 0; ?>
<?php while (have_posts()) : the_post(); $postcount++;?>
<?php $counter++; ?>
<div class="block<?php if ( !$is_paged && $woo_options['woo_home_one_col'] == "false" ) echo ' two-col'; ?><?php if ($counter == 2) { echo ' last'; $counter=0; } ?>">
<div class="box post">
<div class="date-comments">
<p class="fl"><?php the_time( get_option( 'date_format' ) ); ?></p>
<p class="fr"><span class="comments"></span><?php comments_popup_link(__('0 Kommentare', 'woothemes'), __('1 Kommentar', 'woothemes'), __('% Kommentare', 'woothemes')); ?></p>
</div>
<h4 class="title"><a title="<?php _e('Link zu', 'woothemes'); ?> <?php the_title(); ?>" href="<?php the_permalink() ?>" rel="bookmark"><?php if (strlen($post->post_title) > 30) {
echo substr(the_title($before = '', $after = '', FALSE), 0, 30) . '...'; } else {
the_title();
} ?></a></h4>
<?php if ( $woo_options['woo_content_normal'] != "content" AND !( $woo_options['woo_home_one_col'] == "true" AND woo_embed('') ) ) woo_image('width='.$woo_options['woo_thumb_image_width'].'&height='.$woo_options['woo_thumb_image_height'].'&class=post-thumbnail'); ?>
<?php if ( $woo_options['woo_home_one_col'] == "true" ) echo woo_embed('key=embed&width=540&height=400'); ?>
<div class="entry">
<?php the_advanced_excerpt(); ?>
</div>
<div class="fix"></div>
<!--/* <?php if ( $woo_options['woo_content_normal'] != "content" ) { ?><span class="continue"><a title="<?php _e('Link zu', 'woothemes'); ?> <?php the_title(); ?>" href="<?php the_permalink() ?>" ><?php _e('Zum Deal', 'woothemes'); ?></a></span><?php } ?>*/-->
<div class="date-comments2" style="border-bottom:0px; border-top:1px solid rgb(202,202,202);">
<p class="fl2"><a href="<?php the_permalink() ?>" style="color:#3e8bb7;">Zum Deal</a></p>
<p class="fr2">Kategorie: <?php the_category(', ') ?></p>
</div>
</div> <!-- end .box -->
</div> <!-- block -->
<?php if ( $counter == 0 && !$is_paged && $woo_options['woo_home_one_col'] == "false" ) { ?><div class="fix"></div><?php } ?>
<?php endwhile; ?>
<?php endif; ?>
<div class="fix"></div>
<?php if(function_exists('wp_paginate')) {
wp_paginate();
} ?>
</div><!--/centercol-->
<?php get_sidebar(); ?>
<?php get_footer(); ?>
Alles anzeigen
Wer weiß woran das liegen könnte? Vielen Dank für eure Hilfe!
Freundliche Grüße
Daniel