TXP Builders

Hello! TXP Builders is a collective of web designers
passionate about making great looking Textpattern powered web sites.

Proposed changes to Textpattern comments forms

Today I sent in some proposed changes to the comments forms of a Textpattern base install.

In case you are new to Textpattern, forms are Textpattern-speak for snippets or includes – essentially a means of including chunks or blocks of content. The main use for forms is repeating content – headers, footers, sidebars and the like.

In a clean install (as of TXP version 4.2), Textpattern offers an in-built mechanism for the control and display of comments. This is very helpful but the markup is a little out of date. In addition, I believe it would be helpful to include more conditional arguments – arguably one of the most impressive of the Textpattern feature-set.

Here is the proposed changeset and printed below.

This proposed changeset does not address the any possible future changes to the comments system

Let me know what you think!

comments_display form

<h3 id="comment"><txp:comments_invite textonly="1" showalways="1" showcount="0" /></h3>

<txp:comments />

<div id="cpreview">
<h3>This is a preview of your comment. Press "Submit" in order to post it.</h3>
<txp:comments_preview form="comments_preview" />

<div id="comments-form" class="clearfix">
<txp:else />
<h3 id="comment" />">Leave a comment:</h3>
<txp:comments_form />

comments form

<txp:comment_anchor />
<div class="comment_post">
<div class="comment_meta">
<txp:comment_name /> <txp:comment_permlink>#</txp:comment_permlink>
<div class="comment_details">
<txp:comment_message />

comment_form form

<txp:comments_error break="li" wraptag="ul" />

<legend>Comment form</legend>
<li><label for="name"><txp:text item="Name" /></label><br /><txp:comment_name_input /></li>
<li><label for="email"><txp:text item="Email - required but not displayed" /></label><br /><txp:comment_email_input /></li>
<li><label for="web"><txp:text item="Website" /></label><br /><txp:comment_web_input /></li>
<li><label for="message"><txp:text item="Your comments" /></label><br /><txp:comment_message_input /></li>
<li><txp:comment_remember /></li>
<li>Style your comments with <txp:comments_help />.</li>
<li><txp:comment_preview /> <txp:comment_submit /></li>

25 April 2010, 20:48 · Jonathan Stubbs

Tweet this · Permalink

Full Tag list

Back to the blog