get_posts() with category filter not working (1 post)

  1. SchattenMann
    Posted 5 years ago #


    im facing a huge headache cuz in the past 4h i wasn't able to do a simple thing as

    $myposts = get_posts('numberposts=5&category=1');

    print_r($my_posts);// returns array();

    if i simple remove 'category' => 1 it works as is expected...

    and yes, category have posts!

    i found a lot of people facing this problem but the threads seems to finish with no answer...

    no plugins are installed and i have read all the template code and nothing seems to use get_posts or add any filter/change

    also, im testing it on default theme

    some help is appreciate!

Topic Closed

This topic has been closed to new replies.

About this Topic


No tags yet.