get_posts not returning all posts

Problem is your ‘numberposts’ is set to 4 Put it at -1 to get all posts:

 'numberposts'       => -1,

If you don’t set numberposts here, WordPress will pull the number of posts from your Dashboard settings (under Settings -> Reading)

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)