ID; $author_posts_text = bloglex_get_option('author_posts_text'); $no_of_author_posts = absint(bloglex_get_option('no_of_author_posts')); $order = esc_attr(bloglex_get_option('author_posts_order')); $orderby = esc_attr(bloglex_get_option('author_posts_orderby')); $enable_author_posts_author_meta = bloglex_get_option('enable_author_posts_author_meta'); $select_author_posts_author_meta = bloglex_get_option('select_author_posts_author_meta'); $author_posts_author_meta_title = bloglex_get_option('author_posts_author_meta_title'); $enable_author_posts_date_meta = bloglex_get_option('enable_author_posts_date_meta'); $select_author_posts_date = bloglex_get_option('select_author_posts_date'); $single_author_post_date_meta_title = bloglex_get_option('single_author_post_date_meta_title'); $select_author_posts_date_format = bloglex_get_option('select_author_posts_date_format'); $enable_author_posts_category_meta = bloglex_get_option('enable_author_posts_category_meta'); $author_posts_category_label = bloglex_get_option('author_posts_category_label'); $select_author_posts_category_color = bloglex_get_option('select_author_posts_category_color'); $select_author_posts_number_of_category = bloglex_get_option('select_author_posts_number_of_category'); // Covert id to ID to make it work with query if ('id' == $orderby) { $orderby = 'ID'; } $author_posts_args = array( 'author' => get_the_author_meta('ID'), 'post_type' => 'post', 'post__not_in' => array($post_id), 'posts_per_page' => $no_of_author_posts, 'ignore_sticky_posts' => 1, 'orderby' => $orderby, 'order' => $order, ); $author_posts_query = new WP_Query($author_posts_args); if ($author_posts_query->have_posts()): ?>

have_posts()):$author_posts_query->the_post(); ?>