On the single post page I need to be able to display a list of five of the latest posts from a certain custom post type. It should work something like a changelog. They need to be displayed in this format:
(published date) (post content)
(published date) (post content)
(published date) (post content)
(published date) (post content)
(published date) (post content)
In general I know what to look for and how to do it by editing the theme, but I'm wondering if there is any plugin or combination of plugins that will help me accomplish this easier than editing the theme files? I'm not lazy about doing that, but I need to do it on many new wordpress sites that need to be built fast and I don't have the time to edit every wordpress theme manually.
Here is a practical example for this: There is a post on the site about a certain online software which is popular and gets traffic. A changelog has to be displayed in the post which needs regular updates. So the admin of the site can simply enter the new changelog in a sentence, click publish and it will show in the post about the software and thus create a list with change logs.
Thanks!
you can use the following code
<?php $args = array( 'post_type' => 'your post name here','posts_per_page' => 5 );
$myposts = get_posts( $args );
foreach ( $myposts as $post ) : setup_postdata( $post ); ?>
<?php echo get_the_time('Y-m-d', $post->ID);
echo the_content();
?><?php endforeach;