Question about "Site Name" and some other aspects

This is a FORK of the CMS Made Simple project and is not oficially supported in any way by the CMS Made Simple development team.
Locked
Alexander_Grig
New Member
New Member
Posts: 4
Joined: Thu Nov 12, 2009 2:32 pm

Question about "Site Name" and some other aspects

Post by Alexander_Grig »

Hi!

I need to create a site with 3 languages: English, Russian and Ukrainian. I installed the program "cmsms-mle-1.6.6-full.tar.gz" in accordance with the procedures described in http://econtools.economia.unife.it/cmsm ... /mle16.htm. I also read - http://forum.cmsmadesimple.org/index.ph ... 318.0.html because the Ukrainian language was not present in the installation list.

My site uses the template "Left simple navigation + 1 column", which was modified as described here - http://econtools.economia.unife.it/cmsm ... /mle16.htm.

I have several questions:

1) I noticed that when you switch to Russian (and Ukrainian as well), the following text is not translated for some reason:
the bottom of the page - "Next page:" (in Russian it must be "Следующая страница"), "^ Top" (in Russian it must be "^ Наверх"), in the search string there is text "Enter Search ..." instead of "Введите запрос..." in Russian , the whole area (module) of news (headline and news themselves).
Where can I find these word combination to translate them manually? Are they located in one of the files "\modules\MODULENAME\lang\ (eg, \ modules \ CMSMailer \ lang) ? Or they are located elsewhere.
And how to make the  news module to display only news in the appropriate language?

2) The main question! How to make 3 different site names (in 3 languages) for all of these three language versions of pages. In the "Site Admin» Global Settings »General Settings" there is only one field "Site Name". If you input the text into this field "Site Name", this text will be shown on every version of site (English, Russian and Ukrainian).  
According to the logic there should be a drop-down list of the site languages, where you could select the desired language and enter a Site Name in this language (as is done for content pages).

I was looking for the answer on this question, and found - http://forum.cmsmadesimple.org/index.ph ... l#msg86552 "Tips and Tricks - # 7" (there are some problems with the video - http://econtools.economia.unife.it/cmsms_tools/tr.htm ).
I tried to use this tip. In "TranslationManager" for Russian and English languages, I created a record "shapka" for the text "ПРимер текста" (Russian) and "Text Sample" (English), then in the template
"Left simple navigation + 1 column" I use the expression:

(tr_key key = "shapka" lang = "$lang" assign = "mystring222")
and then in the text of template, for example:
{sitename} - {$mystring222} - {title}
This works.
But if you enter "$mystring222"
 or "{$mystring222}"
 in the field of "Site Admin» Global Settings »General Settings" »" Site Name ", the text at the top of the page where text of " Site Name " is located will display "$mystring222"   or "{$mystring222}", not "Пример текста" (Russian) and "Example of text" (English) as I need.

How can I solve this problem? Which files do I need to change?

3) Another question on "TranslationManager": I did not found how can I add a language that is not present in the dropdown list "1. Language of file:" (the tab "New / Import language") . I need to work with the Ukrainian, which is not present there.
Is it possible?

Thank you for your reply.


P.S. If you are interested, I can make translation to the Ukrainian language. Which files do I need to translate for this? All files wich are present in the folders "\modules\MODULENAME\lang"? Or some other files?
Last edited by Alexander_Grig on Fri Nov 13, 2009 3:10 am, edited 1 time in total.
replytomk3

Re: Question about "Site Name" and some other aspects

Post by replytomk3 »

try duplicating the post on the russian forum section
Peciura

Re: Question about "Site Name" and some other aspects

Post by Peciura »

Are they located in one of the files "\modules\MODULENAME\lang\ (eg, \ modules \ CMSMailer \ lang) ?
Yes, including search module.
..."Next page:" (in Russian it must be "Следующая страница"), "^ Top" (in Russian it must be "^ Наверх")...
Open page template and you will find code

Code: Select all

{anchor anchor='main' text='^ Top'}
I would use translation manager to replace static text "^ Top". Avoid single quotes - use double.
And how to make the  news module to display only news in the appropriate language?
You have to create categories for each language (i assume your language keys are "ru_RU", "en_US",... ; e.g. "category_prafix_ru_RU",  "category_prafix_en_US") and call them

Code: Select all

{news category="category_prefix_$lang" number=3 detailpage="news"}
How to make 3 different site names (in 3 languages)
Open page template find tag "{sitename}" you could create Global Content Block e.g. "sitename-mle" write site name for each language and replace "{sitename}" in the template

Code: Select all

{global_content name='sitename-mle'}
Or you can create key "sitename" in translation manager. (i see you are familiar to it :))

Code: Select all

<title> {sitename} - {tr_key key = "shapka" lang =$lang}  - {title} </ title> 
...I need to work with the Ukrainian,...
I use to Translation manager to create keys like "wedding_cake" that are not present in any module :).
...I can make translation to the Ukrainian language...
My advise is to ask for help in Russian  and Polish boards. Try to contact to katon i believe he knows a lot about Ukrainian language and CMSms-mle-fork.


You are on right way - carry on.
Alexander_Grig
New Member
New Member
Posts: 4
Joined: Thu Nov 12, 2009 2:32 pm

Re: Question about "Site Name" and some other aspects

Post by Alexander_Grig »

Peciura, thanks for advice to use Global Content Blocks. Problems with Site name, Next page, Previous page and Top I solved with its help ( I decided not to use TranslationManager module).

========================================================
I created 4 Global Content Blocks:

1)
Name:   sitename-mle
Tag to Use this Block:  {global_content name='sitename-mle'}
Content (in English):   Site name in English
Content (in Russian):   Название сайта на русском
Content (in Ukrainian): Назва сайту на українській мові
2)
Name:   Next-mle
Tag to Use this Block:  {global_content name='Next-mle'}
Content (in English):   {cms_selflink dir="next" label="Next page: "}
Content (in Russian):   {cms_selflink dir="next" label="Следующая страница: "}
Content (in Ukrainian): {cms_selflink dir="next" label="Наступна сторінка: "}
3)
Name:   Previous-mle
Tag to Use this Block:  {global_content name='Previous-mle'}
Content (in English):   {cms_selflink dir="previous" label="Previous page: "}
Content (in Russian):   {cms_selflink dir="previous" label="Предыдущая страница: "}
Content (in Ukrainian): {cms_selflink dir="previous" label="Попередня сторінка: "}
4)
Name:   top-mle
Tag to Use this Block:  {global_content name='top-mle'}
Content (in English):   {anchor anchor='main' text='^ Top'}
Content (in Russian):   {anchor anchor='main' text='^ Наверх'}
Content (in Ukrainian): {anchor anchor='main' text='^ Вгору'}

After this I made changes in Template "Left simple navigation + 1 column":

{sitename} - {title}
was replaced by
{global_content name='sitename-mle'} - {title}

{sitename}
was replaced by
{global_content name='sitename-mle'}

{anchor anchor='main' text='^ Top'}
was replaced by
{global_content name='top-mle'}

{cms_selflink dir="previous" label="Previous page: "}
was replaced by
{global_content name='Previous-mle'}

{cms_selflink dir="next"}
was replaced by
{global_content name='Next-mle'}

==========================================
Also I made another little change (to delete text 'You are here' and place space between flags and current position "Home » How CMSMS Works...")
{lang}{breadcrumbs starttext='You are here' root='Home' delimiter='»'}
was replaced by
{lang} &nbsp {breadcrumbs starttext='' root='Home' delimiter='»'}
==========================================


But question with Search form is still open:

Enlish version (ok):
-----------------------------
Text near search field:  "Search: "
Text in search field: "Enter Search..."
Text on the button:   "Submit"

Russian version (now):
-------------------------------
Text near search field:  "Поиск :"
Text in search field:     "Enter Search..."
Text on the button:   "Искать"

Russian version (which I need)
----------------------------------------
Text near search field:  "Поиск :"
Text in search field:    "Введите текст..."
Text on the button:   "Искать"

Ukrainian version (now):
---------------------------------------
Text near search field:  "Поиск :"
Text in search field:    "Enter Search..."
Text on the button:   "Искать"

Ukrainia version (which I need)
--------------------------------------------
Text near search field:  "Пошук:"
Text in search field:    "Введіть текст..."
Text on the button:   "Шукати"
================================

I tried to find corresponding text in \modules\Search\lang\xx_XX.php file, but I can't find it there.
So could you tell me how can I change (manually) text near the search field, in the search field and on the Search button.
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: Question about "Site Name" and some other aspects

Post by Dr.CSS »

The Enter Search text is in the search admin and you may see the call in the search template, you may find the lang. string in search module folder, if you need a lang. file that isn't in there copy one of the others and replace the parts you need and save it as that languages lang. file...
Peciura

Re: Question about "Site Name" and some other aspects

Post by Peciura »

/modules/Search/lang/ext/ru_RU.php

Code: Select all

$lang['search'] = 'Поиск ';
Well call search tag like

Code: Select all

{search lang=$lang}
Also check search module parameters in search module help:
Extensions » Modules > Module Help
Locked

Return to “[locked] CMSMS MLE fork”