I need to get 5 attachments (images) from 5 newest posts from given category (‘foobar’) in WordPress. At the moment I can do it by calling two functions separately (WP_Query and get_children):
But I’m looking for simpler solution (maybe with use of wpdb?) Is there any?
- The topic ‘Get attachments from posts from given category’ is closed to new replies.