• Hi everyone. I searched for an answer but couldn’t find anything. I apologize in advanced if this has been discussed before. I would like my home page to show all images expanded. Right now, only the first post shows fully, then the rest or recent posts show collapsed and you have to click on the Title to see the post. I would like to make at least the latest 3 posts to show fully. I really can’t figure this out and would appreciate if you can h elp me. I am using That-Music template, slightly modified.

    Thanks,

    Dave

Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter dabitz

    (@dabitz)

    Thread Starter dabitz

    (@dabitz)

    Michael, I made the change and it work. I have the problem now that this templage (That-Music) doesn’t show the “Next Page” link at the bottom of the pages. So if I choose to display 10 posts on the home page and I have made 20, 10 of them cannot be seen.

    Can you help me out? Please note that I don’t write PHP code ?? I can’t figure this out myself, sorry…

    Thanks so much,

    Dave

    My index page:

    <?php get_header(); ?><div id=”left” class=”grid_9 omega alpha”><div id=”content”> <?php if ( $paged < 2 ) { // Do stuff specific to first page ?> <?php $my_query = new WP_Query(‘showposts=1’);while ($my_query->have_posts()) : $my_query->the_post();$do_not_duplicate = $post->ID; ?> <div class=”entry”> <h2 class=”sectionhead”>Latest Entry</h2> <div class=”post” id=”post-<?php the_ID(); ?>”> <h2>” rel=”bookmark” title=”Permanent Link to <?php the_title(); ?>”> <?php the_title(); ?> </h2> <p class=”postinfo”> <?php the_time(‘M j, Y’) ?> <?php the_category(‘, ‘) ?> <?php comments_popup_link(‘Leave a comment’, ‘1 Comment’, ‘% Comments’); ?> <?php edit_post_link(‘Edit’, ‘ | ‘, ”); ?>
    Posted by <?php the_author(); ?> </p> <?php the_content(‘Read More..‘); ?> </div> </div> <?php endwhile; ?> <div class=”entry”> <h2 class=”sectionhead”>Recent Entries</h2> <?php if (have_posts()) : while (have_posts()) : the_post();if( $post->ID == $do_not_duplicate ) continue; update_post_caches($posts); ?> <div class=”post” id=”post-<?php the_ID(); ?>”> <h2>” rel=”bookmark” title=”Permanent Link to <?php the_title(); ?>”> <?php the_title(); ?> </h2> <p class=”postinfo”> <?php the_time(‘M j, Y’) ?> <?php the_category(‘, ‘) ?> <?php comments_popup_link(‘Leave a comment’, ‘1 Comment’, ‘% Comments’); ?> <?php edit_post_link(‘Edit’, ‘ | ‘, ”); ?>
    Posted by <?php the_author(); ?> </p> <?php the_content(); ?> </div> <?php endwhile; endif; ?> </div> <div class=”entry”> <?php } else { // Do stuff specific to non-first page ?> <div class=”entry”> <h2 class=”sectionhead”>Recent Articles</h2> <?php if (have_posts()) : while (have_posts()) : the_post();if( $post->ID == $do_not_duplicate ) continue; update_post_caches($posts); ?> <div class=”post” id=”post-<?php the_ID(); ?>”> <h2>” rel=”bookmark” title=”Permanent Link to <?php the_title(); ?>”> <?php the_title(); ?> </h2> <p class=”postinfo”> <?php the_time(‘M j, Y’) ?> <?php the_category(‘, ‘) ?> <?php comments_popup_link(‘Leave a comment’, ‘1 Comment’, ‘% Comments’); ?> <?php edit_post_link(‘Edit’, ‘ | ‘, ”); ?>
    Posted by <?php the_author(); ?></p> <?php the_content(‘Read More..‘); ?> </div> <?php endwhile; endif; ?> <div class=”next_nav”> <div class=”alignleft”> <?php next_posts_link(‘« Older Entries’) ?> </div> <div class=”alignright”> <?php previous_posts_link(‘Newer Entries »’) ?> </div> </div> <?php } ?> </div> <div class=”clear”></div> </div></div><?php get_sidebar(); ?><br clear=”all” /></div><?php get_footer(); ?>

    You have two loops so I don’t believe you will be able to control the number of posts on the whole page–just in one of the loops–and it looks like you already have previous_posts_link and next_posts_link in the 2nd loop there.

    Make sure your Administration > Settings > Reading has the correct value in Blog pages show at most

    Thread Starter dabitz

    (@dabitz)

    I bumped the “show at most” to 15 because the next page link isn’t showing. No idea what loops mean. Even under categories, the next page isn’t showing. The site is at https://www.santanastown.com/blog

    Is there any hope or should I switch to another templage? I was really happy with this one.

    Well you could change to the WordPress Default theme just to see how the previous/next stuff looks.

    The two loops you have in that index.php were
    1. first loop starts with $my_query = new WP_Query('showposts=1');while ($my_query->have_posts())
    2. 2nd loop starts with Recent Entries</h2> <?php if (have_posts()) : while (have_posts()) : the_post(); and there’s some else logic that has another loop at else { // Do stuff specific to non-first page ?> <div class="entry"> <h2 class="sectionhead">Recent Articles</h2> <?php if (have_posts()) : while (have_posts()) : the_post();

    Another theme might be better…

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Show posts expanded on home page’ is closed to new replies.