textpattern ~ code ~ css

Oct 20 2007

Plugin: mg_recent_comments

The plugin <txp:mg_recent_comments /> makes a few small changes to the stock recent_comments tag offered in Textpattern. The link is given a title and the commentor’s name appears.


This plugin takes the same attributes as the standard recent_comments tag, which can be found here. The only changes this plugin makes are to the appearance of the link and the title of the link.


<txp:mg_recent_comments wraptag="ul" break="li" limit="3" class="comments-list" />

The above produces a ul of links like this, with the class “comments-list”:

Notes on Usage

This plugin behaves exactly as the stock <txp:recent_comments /> tag. It’s only change is to the look of the output, and the addition of a title attribute stating the commentor’s name.


Written by Michael Gravel, based, obviously, on the base txp code. I was unhappy with the appearance of the stock code and frustrated by the lack of a title on the link. So here is my solution.

Posted in text on October 20, 2007

No comments

Commenting disabled.


Welcome to the Text archives. This is where I write about Textpattern, a lightweight, PHP-based content management system.

side image

Textpattern Plugins

I've made a few plugins for Textpattern that provide very modest additions to the software's existing functionality. Here they are: