You are currently having 2 loops, while you only need one. Something like this should work:
<ul>
<?php
$args = array( 'post_status' => 'pending');
$recent_posts = wp_get_recent_posts ( $args );
foreach( $recent_posts as $recent ){
echo '<li><a href="' . get_permalink( $recent["ID"] ) . '" title="' . esc_attr( $recent["post_title"] ) . '">';
echo get_the_post_thumbnail($recent["ID"], 'thumbnail');
echo '</a></li>';
echo '<li class="vote-title"><a href="' . get_permalink($recent["ID"]) . '" title="Look '.esc_attr($recent["post_title"]).'" >' . $recent["post_title"].'</a> '. $recent["the_author"].' </li>';
}
?>
</ul>
Related Posts:
- GET the excerpt by ID
- How can you change the ‘Insert into Post’ title in the media button?
- $post->ID and the_id() always return the wrong value
- Is it possible to direct users to a certain post based on a password entered on the home page?
- Callback for wp.autosave.server.triggerSave();
- Search & Remove Specific Shortcode From All Posts
- How to get Category Id from Post Id ?
- What is the best / efficient way to get WordPress content by post id and why?
- Where can I find the code how wordpress parses a post?
- Delete Child Posts
- Include Sticky Post in Page Posts Count?
- Get only modified posts
- Pagination for Pages and Posts
- How to choose a sort order (for posts) per category? (ideally when creating a new category)
- Remove inline width from figure
- How to lock a post or page
- orderby=meta_value_num creates duplicate posts
- Custom fields on a virtual page
- Create post using JSON api plugin
- Query posts from different categories in multisite
- How to bring an old edited/modified post in the front of page?
- Display all months with posts and inside each month show the 5 latest posts
- Is there a way to backdate posts?
- How to make search for the custom post type?
- WordPress post tag & custom field
- posts_nav_link() not displaying anything
- Adding footers to posts?
- Injecting JavaScript into a Post with WP3.x
- Visual / HTML tabs vanished on editor
- Display post from specific date
- Why won’t my taxonomy query show up?
- WP_Query with ajax handler returns the same posts
- How to display posts on a static page? (like search loop)
- How to show single post page as home page
- Why WP_Query(‘showposts=5’) shows only 1 post?
- WP Remote Request not returning all of content via request
- Get more than one author’s posts with REST API
- Unable to Add/ Edit Post in WordPress
- How to copy posts from one site to another in real time (not multisite)
- More then one menu items are assigned with “current-menu-item” class
- How can i delay reading posing in 3days for not logined user?
- Get attachments for posts that belongs to a specific category
- why are images not full size?
- Anyone know why wordpress converts some html entities to their numeric equivalents?
- How to Mysql select a list of posts with meta_values AND all relevant categories?
- Nested WP_Query breaking loop
- How to create wordpress class with post meta? [closed]
- In post.php how can I remove onbeforeunload?
- Custom taxonomy archive page problem
- post__in not working with pre_get_posts, but post__not_in does work
- Query posts and filter at query time by value of custom meta
- Blog page error ‘Index of /blog’
- Update post meta within save_post action
- tribe_get_start_time displays the current date and time on other post types than tribe_events
- Auto delete posts based on content text
- Count the number of a post types associated with another post type
- How to get the latest URL of my blog?
- How do post IDs work in WordPress?
- Hide parts of the post content after typing it’s name or searching it by category
- search content of pages and list in wp-admin
- adding my posts (author posts) in menu
- How to separate each individual blog post?
- get parent fields title, content excerpt etc
- Changing permalink of WordPress
- Rest API Paginate until all posts are imported
- Group first, 2nd, 3rd, etc posts by category terms
- exclude particular category in api
- wp_trash_post() duplicates post to trash
- How to backup WP blog posts to computer, not new site
- Make categories appear random
- Create Posts from API response without duplicates
- I want to change the WordPress comments file
- How to find the edit link of the WordPress Post from the URL
- Blog Page doesn’t show summary but full content
- Get posts from category from custom query
- Changing a users posts to drafts upon role change
- Show 5 posts and than 3 posts offset with pagination
- Alternative content between posts no repetition
- Start loop from specific post ID
- Connection dropped due to file size
- How to Get Position of a Post from a category and tag
- Custom author search
- Create new post on user registration
- Ajax – Post Categories and Load More
- Skip posts, but keep posts per page
- Display the current post author and his url in the post header
- How to limit the number of results for all query_posts on mysite
- Only display price when value exist
- Output posts with same name as tags?
- The next_posts_link() works only with original $wp_query
- Latest news mini images
- User driven content problems
- How to make a posts page display only intros of posts?
- Admin moderates ALL comments (including post author)
- Load posts from external source if not found in database
- jquery: getting contents of #content field on post page
- How to show total view count across all posts for an author
- Post dynamic fields and style
- Dynamic archive of posts by date
- Name Registry (forum?) – Self Entered