dannyman.toldme.com


Technical, WordPress

My First WordPress Hack

As posted to WordPress Hacks:

Hey. I wanted to be able to see posts that had been “recently modified” as opposed to the date posted. This way I can add entries out-of-order, but still advertise them on my sidebar.

I hacked the get_archives() function to add a recentlymod option. You can see the following function call in use under “Recent Posts.”

get_archives('recentlymod', 7);

The hack is available at http://dannyman.toldme.com/scratch/wp-template-functions-general.diff.

Personally, I would like WP to have an admin feature to distinguish between post_date and post_modified … a toggle I could set somewhere to ensure that my RSS feed was behaving as “Recent Posts” does.

Now I can post stories from my World Tour (still not finished yet!?) and my readers will have a clue that new material has appeared.

Read More

Next:
Previous:
Categories: Technical, WordPress
Possibly-Related Posts

Comment

Leave a comment . . .

Tiny Print:

  1. For private messages, e-mail me: dannyman@toldme.com.
  2. You must provide an e-mail address.
  3. You can use a bogus e-mail address, but I like to know who you are.
  4. I will not spam you. I will not publish or share your e-mail address.
  5. First-time commenters will be held for review.
  6. You can use these HTML tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>