Title: Posts updated
Last modified: August 18, 2016

---

# Posts updated

 *  [shadow](https://wordpress.org/support/users/shadow/)
 * (@shadow)
 * [21 years, 10 months ago](https://wordpress.org/support/topic/posts-updated/)
 * Hi,
    I have had a good look through the forums and the Wiki, but can’t find exactly
   what I am looking for. Has anyone seen a plugin that allows for showing the latest
   posts that have been updated? Thanks for any advice 🙂

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [oriecat](https://wordpress.org/support/users/oriecat/)
 * (@oriecat)
 * [21 years, 10 months ago](https://wordpress.org/support/topic/posts-updated/#post-71212)
 * By updated, I assume you mean edited?
    Ok, just for fun, I decided to see if 
   I could do this. On one of my sites, I have been using a Recent Posts hack. So
   I modified it to pull posts where the post_date < post_modified. At first I got
   an error but then I edited a post (in case there were none for it to pull!) and
   it seems to work. See here: [http://moltenwords.net/pp101/](http://moltenwords.net/pp101/)
   It says Recent Posts, but I didn’t change that. Here is the code I used: `<?php
   function get_edited_posts($no_posts = 5, $before = '
    - ', $after = '
    - ', $show_pass_post = false, $skip_posts = 0) {
       global $wpdb, $tableposts;
      $request = "SELECT ID, post_title FROM $tableposts WHERE post_date < post_modified";
      if(!$show_pass_post) { $request .= "AND post_password ='' "; } $request .="
      ORDER BY post_date DESC LIMIT $skip_posts, $no_posts"; $posts = $wpdb->get_results(
      $request); $output = ''; foreach ($posts as $post) { $post_title = stripslashes(
      $post->post_title); $permalink = get_permalink($post->ID); $output .= $before.'
      [' . $post_title . '](https://wordpress.org/support/topic/posts-updated/"&apos;?output_format=md)'.
      $after; } echo $output; } ?> It would go in your my-hacks file, then on the
      index.php you would need to include `<?php get_edited_posts(); ?>` where you
      want them to be. This is my first attempt at modifying anything like this,
      so I make no guarantees. 🙂
 *  Thread Starter [shadow](https://wordpress.org/support/users/shadow/)
 * (@shadow)
 * [21 years, 10 months ago](https://wordpress.org/support/topic/posts-updated/#post-71221)
 * Thanks Oriecat:)
    I will have a play with it later today and see how it goes.
 *  [dannyman](https://wordpress.org/support/users/dannyman/)
 * (@dannyman)
 * [21 years, 7 months ago](https://wordpress.org/support/topic/posts-updated/#post-72023)
 * Another [recently modified hack](http://wordpress.org/support/index.php?action=vthread&forum=10&topic=10050).
   😉

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Posts updated’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 3 replies
 * 3 participants
 * Last reply from: [dannyman](https://wordpress.org/support/users/dannyman/)
 * Last activity: [21 years, 7 months ago](https://wordpress.org/support/topic/posts-updated/#post-72023)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
