Textpattern 4.0.7

Comments 1

The latest and greatest version of Textpattern was released about a week ago. (Yes I’m a bit late with this but hey, I try.) There are the usual bug-fixes along with several new tags and some radical re-coding.

The re-coding is down to the new tag parser. It now allows “tags-within-tags” without the need for a plug-in. In fact you can have “tags-within-tags-within-tags-etc” to (as far as I am aware) an unlimited depth with the correct escaping of the tags. You can also “nest” the same tag within itself ie:-

<txp:if_section name="default">
blah blah
<txp:else />
<txp:if_section name="about">
blah blah
<txp:else />
blah blah

New tags include <txp:variable> and <txp:if_variable> which, along with the new parser, extend Textpattern’s flexibility to a point I haven’t managed to reach yet. An example of these new tags combined with the new parser could go something like:-

<dd><txp:comment_name link="0" /></dd>
<txp:variable name="website" value='<txp:comment_web />' />
<txp:if_variable name="website" value="">
<txp:else />
<dd><a href="http://<txp:comment_web />"><txp:comment_web /></a></dd>
<dd><txp:comment_time /></dd>
<dd><txp:comment_time format="%I:%M %p" /></dd>

Note how the <txp:variable> tag uses the new “tags-within-tags” facility. The <txp:if_variable> conditional tag is then used to compare the variable value allowing us to display a website name if one has been entered or remove the line completely if one hasn’t.

Other new tags include <txp:if_keywords>, <txp:modified>, <txp:expires>, <txp:if_expired>, <txp:if_expires>, <txp:if_first_section>, <txp:if_last_section>, <txp:if_first_category> and <txp:if_last_category>.

Apart from those there are a large number of existing “single” tags that can now be used as “container” tags.

There is a new block on the “Write” page corresponding to the new “expire” tags and a number of other changes to the “back-end” allowing more search parameters etc.

To celebrate this latest version I have released TXP Falling Away, a new theme using some of the new functionality and I have also updated my admin theme A Bit Blue.

What else can I say? Well if you already use Textpattern go and update it. If you don’t use it then go check it out.



  1. Willie Ray

    I’ve been waiting for 4.0.7 since I heard, so I can change my websites over from the other CMS.
    Right now I’m coding and sitting up my grid layout.

Commenting has expired for this article.

← Older Newer →