Or, embed this snippet using GenerateWP WordPress Plugin.

Download

Clone

Current author’s posts

// WP_Query arguments
$args = array (
	'post_type'              => array( 'post' ),
	'post_status'            => array( 'publish', ' draft' ),
	'author_name'            => 'current',
	'nopaging'               => false,
	'posts_per_page'         => '-1',
);

// The Query
$author_query = new WP_Query( $args );

// The Loop
if ( $author_query->have_posts() ) {
	while ( $author_query->have_posts() ) {
		$author_query->the_post();
		// do something
	}
} else {
	// no posts found
}

// Restore original Post Data
wp_reset_postdata();