Page 1 of 1
News modul: news_return as parameter
Posted: Mon Mar 13, 2006 6:00 pm
by nils73
I just stumbled upon this because I wanted to replace the "Return" link with something more descriptive. But then I found out that it's hardcoded in the language-file. Since I can define almost everything in news, this would be very helpful either. If it's a feature and not a but, please move it to feature requests.
Regards,
Nils
Re: News modul: news_return as parameter
Posted: Mon Mar 13, 2006 6:26 pm
by calguy1000
It is possible to override any lang string in any module, by creating a directory structure similar to the modules directory and overriding only the strings you want to customize.
For example, to override the "Return" string in the news lang file
you can:
Code: Select all
mkdir <install_dir>/module_custom/News/lang
cd <install_dir>/module_custom/News/lang
and add only the strings you want to customize into the language specific file
i.e add:
Code: Select all
$lang['news_return'] = 'BlahBlahBlah';
into a new en_US.php file
Hope this helps.
Re: News modul: news_return as parameter
Posted: Tue Mar 14, 2006 9:30 pm
by nils73
Yes, I know I can do that. But it seems a bit "far out" and not very user-friendly. That is because everything else can be managed and customized via backend (i.e. parameters). I guess this applies to the return-parameter as well.
I helped myself and modified the language-file directly. But a content-editor couldn't do that.
However I am glad you pointed out a different solution than mine.
Regards,
Nils
Re: News modul: news_return as parameter
Posted: Tue Mar 14, 2006 9:55 pm
by calguy1000
I implemented this solution as a reasonable (though not nice) way to over-ride and change the wordings of any string in a module without having to modify the lang file itself. This is because the next time you upgrade, if you modified the lang file directly, your change would probably be lost.
I've been thinking about how to do that in a nice convenient way, but it would probably involve putting all of the lang entries into the database.
And, well, there aren't enough hours in the day/week/month/year to do all of the things on my list as it is

Re: News modul: news_return as parameter
Posted: Sat Apr 22, 2006 4:51 pm
by nils73
calguy,
first I didn't exactly realize how much power your post unleashed! It is simply as great as ... [fill in whatever you think is greatest] and I can only say "Chapeau!" ...
I wonder why I have been using other CMS before. Wow.
Regards,
Nils