Modifiy Comments

Random stuff about serendipity. Discussion, Questions, Paraphernalia.
Post Reply
gman
Posts: 2
Joined: Wed Nov 16, 2005 4:08 am

Modifiy Comments

Post by gman »

Can someone tell me how I can remove text from the comments popup window. I would like to make it a very simple clean comment box.


Enclosing asterisks marks text as bold (*word*), underscore are made via _word_.
Standard emoticons like :-) and ;-) are converted to images.
E-Mail addresses will not be displayed and will only be used for E-Mail notifications
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Modifiy Comments

Post by garvinhicking »

You'll need to edit your commentform.tpl template. The text that is shown there is coming from each plugin, that will instruct your visitor what information applies.

Remove this line:

Code: Select all

{serendipity_hookPlugin hook="frontend_comment" data=$commentform_entry}
Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
BabeSpot

Post by BabeSpot »

But after removing that line also the captcha to prevent comment spam is gone...
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Post by garvinhicking »

Okay, I didn't know you wanted to preserve that. :)

Well, I'm afraid then for that to work you'll have to edit the corresponding plugin files (like serendipity_event_bbcode.php) and modify their frontend_comment hook to not echo the guidelines.

For serendipity 1.0 I've just created custom CSS classes for that, by replacing things like:

Code: Select all

                        echo '<div class="serendipity_commentDirection">' . PLUGIN_EVENT_BBCODE_TRANSFORM . '</div>';
with

Code: Select all

                        echo '<div class="serendipity_commentDirection serendipity_comment_bbcode">' . PLUGIN_EVENT_BBCODE_TRANSFORM . '</div>';
so that you can then use this CSS:

Code: Select all

.serendipity_comment_bbcode {
  display: none;
}
Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Post Reply