Tags:
create new tag
, view all tags

Question

The comment plugin adds the name of the person at the end of the comment, after a linefeed. How can I remove this linefeed? I just want the name to be appended at the end of the comment without an additional line.

Currently, it is:

Test Topic

Test comment

-- Main.chemirac - 09 Jul 2007 06:44:50

I would like it to be:

Test Topic

Test comment -- Main.chemirac - 09 Jul 2007 06:44:50

I would like to know which file needs to be edited and what modifications are to be made (I am a zero on perl and require some spoonfeeding smile )

Environment

TWiki version: TWikiRelease02Sep2004
TWiki plugins: DefaultPlugin , CalendarPlugin , ChecklistPlugin , CommentPlugin , CounterPlugin , HistoryPlugin , SectionalEditPlugin , SmiliesPlugin
Server OS: Windows 2000
Web server: Apache
Perl version: 5.8.7
Client OS: Windows 2000
Web Browser: IE 6
Categories: Plugins

-- ChengappaCB - 09 Jul 2007

Answer

ALERT! If you answer a question - or have a question you asked answered by someone - please remember to edit the page and set the status to answered. The status is in a drop-down list below the edit box.

What happens if you add

%TMPL:DEF{PROMPT:threadmode}%%TMPL:P{promptbox}%%TMPL:END%

%TMPL:DEF{OUTPUT:threadmode}%%POS:BEFORE%
%URLPARAM{"comment"}% -- %WIKIUSERNAME% - %DATE%
%TMPL:END%
to your local UserCommentsTemplate?

-- FranzJosefGigler - 09 Jul 2007

Thanks for your answer Franz. After asking you guys, I was doing my own experiments. I removed a linefeed in the file CommentsTmpl to change:

%URLPARAM{"comment"}%

-- <b>%WIKIUSERNAME% - %DATE% %TIME%</b>
%TMPL:END%

to

%URLPARAM{"comment"}%
-- <b>%WIKIUSERNAME% - %DATE% %TIME%</b>
%TMPL:END%

and now it looks like it is working. Did I do it right ?

-- ChengappaCB - 09 Jul 2007

Yes, that's good enough. TWiki interprets an empty line as in the original template as "new paragraph". You removed that line, so now TWiki formats %URLPARAM{"comment"}% and the signature as if they were written in the same paragraph - which is displayed in the same line if there's enough space on the line.

-- HaraldJoerg - 09 Jul 2007

 
Change status to:
Topic revision: r5 - 2007-07-09 - HaraldJoerg
 
Twitter Delicious Facebook Digg Google Bookmarks E-mail LinkedIn Reddit StumbleUpon    
  • Download TWiki
TWiki logo Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2012 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.