WordPress.org

Ready to get started?Download WordPress

Forums

Zenon Lite
[resolved] limited Featured Image on home (16 posts)

  1. stinnie
    Member
    Posted 1 year ago #

    hi!
    First at all: thanks for this great theme!
    The "enable the posts under the blocks on homepage" is activated. Is there a possibility to show only three posts and not all?

    Thank You,
    stinnie

  2. anallabres
    Member
    Posted 1 year ago #

    Hi!

    Same here! Didi you manage to do it?

    Many thanks.

    Ana

  3. stinnie
    Member
    Posted 1 year ago #

    hi ana

    no sorry i`ve still no solution for this.
    tine

  4. anallabres
    Member
    Posted 1 year ago #

    I've managed to do it!

    Just by adding this:
    <?php query_posts('showposts=3'); ?>

    on layout1.php just above <?php if(have_posts()): ?><?php while(have_posts()): ?><?php the_post(); ?>

    Althought just found out it also affects the category pages.

    Hope it helps.

  5. stinnie
    Member
    Posted 1 year ago #

    right - this I`ve tried aswell. I need all Posts on the category page, so this is no solution for me.
    Ive now the upgrade theme, but theres the same.

    tine

  6. Towfiq I.
    Member
    Theme Author

    Posted 1 year ago #

    Add this in your layout1.php file:

    <?php if(is_front_page()) {
    	 $args = array(
    				   'posts_per_page' => '3');
    	query_posts($args);
    } ?>

    before this line:

    <?php if(have_posts()): ?><?php while(have_posts()): ?><?php the_post(); ?>

  7. stinnie
    Member
    Posted 1 year ago #

    THANKS, Towfliq!!

    now it works! I don`t wanted the pagination, so I delete

    <?php if (function_exists("znn_paginate")) {znn_paginate();} ?>
    <div class="hidden_nav"><?php paginate_links(); ?></div>

    in layout1.php

    now it`s perfect.

    thanks a lot!
    A great theme!
    tine

  8. Towfiq I.
    Member
    Theme Author

    Posted 1 year ago #

    marking this as resolved! :)

  9. anallabres
    Member
    Posted 1 year ago #

    Many thanks!!

    Although the pagination is not working. The page 2 stays loading and never does.

    http://anallabres.com/thecafeonthecorner/

  10. Towfiq I.
    Member
    Theme Author

    Posted 1 year ago #

    disable the "ajax pagination" option from the theme options page.

  11. anallabres
    Member
    Posted 1 year ago #

    Thanks. Done that and an error 404 page appears...

  12. Towfiq I.
    Member
    Theme Author

    Posted 1 year ago #

    could you replace this:

    <?php if(is_front_page()) {
    	 $args = array(
    				   'posts_per_page' => '3');
    	query_posts($args);
    } ?>

    with:

    <?php if(is_front_page()) {
    	 $args = array(
    				   'posts_per_page' => '3',
    'paged' => ( get_query_var('paged') ? get_query_var('paged') : 1));
    	query_posts($args);
    } ?>
  13. anallabres
    Member
    Posted 1 year ago #

    Hi Towfiq,

    Thanks for that but still not working :( error 404

  14. Towfiq I.
    Member
    Theme Author

    Posted 1 year ago #

    can you go to settings> Reading and select 3 posts per page and see if that fixes it?

  15. anallabres
    Member
    Posted 1 year ago #

    It does!! Thanks a lot!! You're brilliant.

  16. Towfiq I.
    Member
    Theme Author

    Posted 1 year ago #

    the issue is not resolved actually, because now the category page is also displaying 3 posts, right?

    a wordpress theme reviewer once told me its a core wordpress issue. I am not sure what it is.

    http://wordpress.org/support/topic/explanation-and-workaround-for-error-404-on-category-pagination?replies=1

Topic Closed

This topic has been closed to new replies.

About this Theme

About this Topic

Tags

No tags yet.