[resolved] Archives loop in the sidebar (3 posts)

  1. tuskmaster
    Posted 3 years ago #

    Inside my sidebar.php I have placed the following code:

    get_template_part( 'loop', 'archive' );

    The reason I want to do this, is I want to use the inifiniteLoader to load the posts in the sidebar as you scroll down. (With thumbnails and css.)

    This is working just the way I want it to, on the index.php and archive.php, but in my single.php, it only displays the current post in the sidebar.

    What I'm REALLY trying to do is have a sidebar and archives like this:

    Any ideas? I have been at it for hours and not making any head-way at all. Multiple loops? I dunno. PLEASE HELP!

  2. tuskmaster
    Posted 3 years ago #

    more code... looking for suggestions...

    <div id="primary" class="widget-area" role="complementary">
            <?php while ( have_posts() ) : the_post(); ?>
           <div class="entry-summary">
                <h2 class="entry-title"><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'twentyten' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h2>
    				<?php the_excerpt(); ?>
    			</div><!-- .entry-summary -->
            <?php endwhile; // End the loop. Whew. ?>
    		<a id="inifiniteLoader">Loading... <img src="<?php bloginfo('template_directory'); ?>/images/ajax-loader.gif"></a></div><!-- #primary .widget-area -->
  3. tuskmaster
    Posted 3 years ago #


Topic Closed

This topic has been closed to new replies.

About this Topic