• Resolved stbedesantafe

    (@stbedesantafe)


    I selected the option “Stick this post to the front page” under Publish>Visibility>Public on one of my posts. It does not appear on my front page.

    stbedesantafe.org

    The post I chose was “All Saint’s Day”. It is marked “Featured” on my News (blog) page, but does not appear on the front page.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hi stbedesantafe,

    Could you please explain more about issue?? Did you want ‘Feature’ text display issue in front page sidebar or the post in front page? If you talking about sidebar of front page does not display ‘Feature’, then it only display recent post not sticky.

    Thanks

    Thread Starter stbedesantafe

    (@stbedesantafe)

    When I select the option “Stick this post to the front page”, I expect that the post will appear in full on the front page – in the main content section, not in either sidebar.

    However, nothing appears on the front page (a static page, which is not my blog). All that happens is that the post moves to the top of my blog page (called “News”) with the word “Featured” above it.

    The post that should now appear on the front page is “Sunday Adult Forums; 9:15 am”.

    Hi stbedesantafe,

    When you select static page from setting , page.php template will be used, so you need to add code to show sticky post on front page.

    Add this code somewhere you want to display sticky post.
    ` $args = array(
    ‘posts_per_page’ => 2,
    ‘post__in’ => array(get_option( ‘sticky_posts’ )),
    ‘ignore_sticky_posts’ => 0
    );

    $query = new WP_Query( $args );
    while ( $query->have_posts() ) : $query->the_post();
    //your code to retrieve title,content….
    endwhile;`
    To know more on sticky postAbout sticky post

    Thanks

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Sticky post’ is closed to new replies.