Changing text in comment form

Skinning and designing Serendipity (CSS, HTML, Smarty)
Post Reply
substream
Regular
Posts: 17
Joined: Mon Aug 07, 2006 7:29 pm

Changing text in comment form

Post by substream »

Hello!
I tried to search for it but didn't find anything.
So here I go:

I would like to change the text you can see next to comment form fields.
e.g. it should say "what's your name" instead of just "name" (just an example...)
I cannot find a document where to change those words, the lang-files seem to change only the appearence of the administration-panel.
Thanks for helping out.
Heiko
d_cee
Regular
Posts: 603
Joined: Wed Jan 18, 2006 6:32 pm
Location: UK
Contact:

Post by d_cee »

Hi

I think you should find all the text you want to change in

lang/serendipity_lang_en.inc.php

Dave
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Changing text in comment form

Post by garvinhicking »

Hi!

You can also edit the commentform.tpl file and replace {$CONST.XXX} there with the strings you want to show :)

Best 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/
stm999999999
Regular
Posts: 1531
Joined: Tue Mar 07, 2006 11:25 pm
Location: Berlin, Germany
Contact:

Post by stm999999999 »

Or you make a lang_en.inc.php in your template-directory with the wanted declarations and add this line in your serendipity_config_local.inc.php:

$serendipity['template_individuell_text'] = true;

So, your declarations will survive an update of s9y. (even a modified lang/serendipity_lang_en.inc.php will be overridden by a new s9y-version - a lang_en.inc.php in the template-dir should be untouched)*


(but only if you have one of the latest nightlies!)


* @garvin: It should, or? Whats about a template which has his own lang-file? This will override the user-modified? Could this be a problem for the few templates, which are carried by the core-installation?
Ciao, Stephan
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Post by garvinhicking »

Hi!

That's the wrong variable, you would need

Code: Select all

$serendipity['useTemplateLanguage'] = true;
;)

However modifying the language file in this case is not the best thing, because it would replace fields like "Name" - and those are used in other contexts as well, where "Enter your name" would be inappropriate.

Best 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/
stm999999999
Regular
Posts: 1531
Joined: Tue Mar 07, 2006 11:25 pm
Location: Berlin, Germany
Contact:

Post by stm999999999 »

That's the wrong variable, you would need

Code: Select all

$serendipity['useTemplateLanguage'] = true;
Argh, c&p from a wrong, old, personal version :-(

However modifying the language file in this case is not the best thing, because it would replace fields like "Name" - and those are used in other contexts as well, where "Enter your name" would be inappropriate.
OK, yes: When you want to alter a phrase, which occurs on many places, but you only want to alter the phrase at a single place without a side-effect it would be better to take new language-constants at this place.
Ciao, Stephan
Post Reply