• Hello,

    I can’t manage to have a sticky post showing in the su_posts list. I have enforced the ignore_sticky_posts to no but it doesn’t make any difference.

    Thank you

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support upwsupport

    (@upwsupport)

    Hi @firebird75

    I am sorry for the late reply, we were really busy last time.
    But now, I am fully engaged to help you with the issue!

    I tried to reproduce this issue on my side with a freshly installed version of our plugin. – Unfortunately, I wasn’t able to reproduce this issue.

    Can you please provide more details about the problem?
    Like: wp-version, is-multisite, steps to reproduce with the fresh plugin?

    With those, I can reproduce and debug it on my machine and successfully upload a new version for you and other users!

    Thank you for your understanding,
    I hope you still follow this post!

    Thread Starter firebird75

    (@firebird75)

    Hello,

    Thank you for your reply!

    I am using this shortcode to achieve that :
    [su_posts template=”teaser-loop.php” posts_per_page=”3″ post_type=”post” taxonomy=”category” tax_term=”my-tax-term” tax_operator=”IN” orderby=”date” post_status=”publish”]

    This doesn’t seem to take into consideration sticky posts. If the sticky post isn’t part of the last 3 posts, then it won’t superseed any of these.

    Maybe I missed a parameter in the shortcode?

    Thank you

    • This reply was modified 4 years, 8 months ago by firebird75.
    Plugin Support upwsupport

    (@upwsupport)

    If I understood correctly, you want to remove sticky posts but not in our plugin.

    In that case, I am not able to help you directly by fixing something.
    But I can provide a solution for you.

    1. SU plugin seems to have wrongly set sticky posts excluding.
    2. To fix that please open file includes/shortcodes/posts.php
    3. Find the line of code which contains this $args['ignore_sticky_posts'] = true; – in my case it was 264th line.
    4. Add this $args['post__not_in'] = get_option('sticky_posts'); directly below $args['ignore_sticky_posts'] = true;
    5. It should fix the issue.

    In our plugin, you can show/hide sticky posts in the widget menu at the bottom of the “Filter” tab.

    I hope it helps!

    • This reply was modified 4 years, 8 months ago by upwsupport.
    Thread Starter firebird75

    (@firebird75)

    To be clear, I want sticky posts to be included. I don’t want them to be excluded. Does your solution apply in that case and will thus include sticky posts in the list of posts displayed?

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Sticky posts in su_posts’ is closed to new replies.