Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
#1 2006-09-09 19:33:45
- Rachel Rachel
- Member
- Registered: 2004-09-24
- Posts: 28
help with displaying comments
this is how i want my comments form to look —
if the author enters a URL, their name will be a link to the URL.
if the author enters only an e-mail address, their name will just be text (no mailto: or anything).
name and e-mail are required.
this is the closest i can get:
<a href="<txp:comment_web />"><txp:glx_thiscomment key="name" /></a>
(the glx_thiscomment plugin extracts only the name instead of comment_name which automatically makes it a link)
but because some people enter http:// in front of their url and some don’t, it doesn’t really work.
any ideas? i feel like this is something obvious and simple but i just can’t see it.
thanks.
Offline
#2 2006-09-09 23:39:16
- els
- Moderator

- From: The Netherlands
- Registered: 2004-06-06
- Posts: 7,458
Re: help with displaying comments
Rachel Rachel wrote:
if the author enters a URL, their name will be a link to the URL.
if the author enters only an e-mail address, their name will just be text (no mailto: or anything).name and e-mail are required.
This is the default behaviour, if you have the settings in admin > advanced preferences like this:
- Comments require user name? Yes
- Comments require user email? Yes
- Never display email? Yes
txp:comment_name will output only the name if no url is entered, and otherwise the name will be a link to the author’s url.
but because some people enter http:// in front of their url and some don’t, it doesn’t really work.
Using http:// as the label for the url field (it is in the default ‘comment_form’ form) will usually restrain commenters from entering this again.
Last edited by els (2006-09-09 23:41:50)
Offline
#3 2006-09-11 21:43:07
- Rachel Rachel
- Member
- Registered: 2004-09-24
- Posts: 28
Re: help with displaying comments
okay, i feel like a ‘tard. i missed that ‘never display email’ thing. thanks!
Offline
Pages: 1