The Comment System!

lightstudio

Joined: 2008-05-12
Posts: 6
Posted: Thu, 2008-05-29 15:32

Thanks for taking the time to review this request.

Comment system is excellent. I am trying to customize it however, so that "recent comments" and "Posted by:" components reflect the "Name" (comment.author if user is a guest) element. In addition, I am trying to customize the email transmitted to our address has the author, subject, comment in it. So far, we have the "subject" (renamed to House) and the "comment" (renamed to Major) as well as the new comment's URL (image) come through the mail.

My problem is getting the var= form[author] to work properly! When it show "Recent Comments" the Name (author) field is not displayed. In addition, the email does not reflect that info. The "Posted by guest on Thu 29 May 2008 11:01:02 AM EDT" component only shows "guest" as I've indicated, which we are trying to get that "$form[author]" variable (Name field on the form) to reflect in those areas. Can anyone assist me in these issues? Below is the code in the Comment.tpl file that we adjusted. Note the "arg1" tags. We hoped that arg1=$comment.author would work, but it does not

<p class="info">
{capture name="date"}{g->date timestamp=$comment.date style="datetime"}{/capture}
{if empty($comment.author)}
{if $can.edit}
{g->text text="Posted by %s on %s (%s)"
arg1=$user.fullName|default:$user.userName
arg2=$smarty.capture.date arg3=$comment.host}
{else}
{g->text text="Posted by %s on %s"
arg1=$comment.author|default:$user.userName arg2=$smarty.capture.date}
{/if}
{else}
{if $can.edit}
{g->text text="Posted by %s (author) on %s (%s)"
arg1=$user.fullName|default:$user.userName
arg2=$smarty.capture.date arg3=$comment.host}
{else}
{g->text text="Posted by %s (author) on %s"
arg1=$comment.author|default:$user.userName arg2=$smarty.capture.date}
{/if}
{/if}

Best Regards,

Kurt (Light Studio)