Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
How to manage the output of a comment ?
Hello,
In a default way, a comment is “outpouted” with the “message” and the “name” with a link to the “web” site.
Is it possible to return the “name” and the “web” in a separate way (not with an href) : ex :
The message
The long message
-Mr Elephant – www.elephent .com – dec. 13 2005
I know that I can hack the taghandlers.ph file … but it’s not very cool.
Thanks,
françois.
françois
Offline
Re: How to manage the output of a comment ?
To be more “precis” : in taghandlers.php the function <code>comment_name($atts) </code> TXP return a hyperlink under the “name” if we have a value in “email” or “web”. But I just want the “name” return without the hyperlink.
françois
Offline
#3 2005-12-07 18:06:29
- Mary
- Sock Enthusiast
- Registered: 2004-06-27
- Posts: 6,236
Re: How to manage the output of a comment ?
Not completely. There is comment_web, which just returns the website url. But there’s no equivalent for the commenter’s name. I don’t know why, probably just an oversight.
You can get it working in the meantime with:
<txp:php>echo $GLOBALS['thiscomment']['name'];</txp:php>
Offline
Re: How to manage the output of a comment ?
Super ! Merci Mary !
Obviously it works like a charm : in fact I don’t want the “automactic” link that return TXP cause I use the “web” input in an other way : my comments form require “name”, “country”, “email” and “message” —> and I can collect the country of the visitors to be display like this :
message blabla
Visitor Name – FRANCE – 07 december 2005
Thanks,
françois.
Last edited by fpradignac (2005-12-07 21:03:54)
françois
Offline
Pages: 1