I'm writing my very own theme, as well as in the sidebar I wish to list particulars on three posts having a specific tag ('featured'). Initially I attempted this:

$args = array(
    'posts_per_page' => 3,
    'tag' => 'featured'); 

$recent_posts = wp_get_recent_posts($args);
foreach( $recent_posts as $post ){

But that did not work, rather I acquired merely a single publish, that did not possess the tag (the newest publish within this situation).

I've also attempted it with using numberposts, just attempting to list posts using the tag, indicating more parameters, and seeking to focus on groups instead of tags, none which has labored for me personally, results varying between getting no listing, only the one publish, and often these.

Ideally Let me stay using wordpress_get_recent_posts because it is a great deal simpler and it is certainly the best function to do the job. Consequently Let me bare this question specific to why I am neglecting to make use of the function correctly, instead of alternative solutions using get_posts or querying more directly.

Is probably not easy, because the function reference does not show any tag parameters: http://codex.wordpress.org/Function_Reference/wp_get_recent_posts

May need to further choose with is_tag: http://codex.wordpress.org/Function_Reference/is_tag

Ok, concerning does not appear to become a solution, I authored an answer using get_posts that actually works in exactly exactly the same way. I still have no idea things i was doing wrong with wordpress_get_recent_posts though.

I'd exactly the same problem, although I wasn't attempting to limit by tag. Here's the way i fixed it. Searching in the actual function signature for wp_get_recent_posts (that is in /wordpress-includes/publish.php), a minimum of during my version of Wordpress, shows:

function wp_get_recent_posts($num = 10)

This really is, obviously, not the same as exactly what the Wordpress Codex states. However when I known as the function with wp_get_recent_posts(5), I really got the five newest posts.

Therefore it does not seem like that which you desired to do can be done with this particular function.