rss_posted
Plugin Details
- Download:
- rss_posted v0.1
- Textpattern Forum:
- View discussion
- Plugin Type:
- Regular
- Current Version:
- 0.1
- Status on this site:
- Active
Based on an idea from one of my favorite textpatterners I put together an alternative to the standard <txp:posted/> tag. The major addition is that each part of the date (year, month and day) will be hyperlinked.
This can be used to link to an archive or other page that supports filtering by date. Coincidentally, this can be done using the latest version (0.14) of the rss_suparchive and you can see this in use on the posted dates on this site.
Revision History
// Version 0.1 – 03/38/2005 – Initial release
Plugin Attributes
monthformat
Format for the month part of the posted date. Accepts PHP date format.
Default: ‘F’
Example: monthformat=”m”
dateformat
Format for the day part of the posted date. Accepts PHP date format.
Default: ‘j’
Example: dateformat=”jS”
yearformat
Format for the year part of the posted date. Accepts PHP date format.
Default: ‘Y’
Example: yearformat=”y”
sep1
Text that separates the first and second parts of the posted date.
Default: ’ ’
Example: sep1=”, ”
sep2
Text that separates the second and third parts of the posted date.
Default: ’, ’
Example: sep2=” ”
linktosection
Denotes the section that the category headers will link to when the URL is built.
Default: ‘’
Example: linktosection=”archive”
order
Denotes the order that the date parts will appear. This can be any combination of M, D and Y. The list should be comma separated with NO SPACES.
Default: ‘M,D,Y’
Example: order=”Y,D,M”
Example
Given an example date of March 28, 2005, 3 hyperlinks will be created:
- 2005 will be hyperlinked to /section/2005
- March will be hyperlinked to /section/2005/03
- 28 will be hyperlinked to /section/2005/03/28
