Thursday, 16 January 2020
  9 Replies
  1.7K Visits
0
Votes
Undo
  Subscribe

Hi. I've been playing around to alter the basic COMBO template for the albanian language. I only want to change the options for the printout, that is i only want the albanian translations of the different parts or phrases for the printout not the interface. I've managed to change alot of the different headings and things but for some reason even after altering other bits they dont show in the print out preview. Specifically for the midweek meeting:

1. The first song and prayer text (oddly the "song" has changed to the albanian but not the "prayer")

2. The middle song and the last song and prayer text

3. The final comments text

And for the weekend meeting:

1. The Title "Weekend Meeting" text

2. All "songs" and "prayer" text

I've included a screenshot below. You should be able to see the bits that haven't worked as they will still be in english. 

Thanks in advance for your help.

more than a month ago
·
#6527
Accepted Answer
0
Votes
Undo

I do not see any song that changed, also the opening comments are in English, so I wonder if the screenshot belongs to the problem(s) you describe. Anyway:

Find all occurrences of !SONG! (exactly that, not anything else with song, there are 7 occurrences in the COMBO_1 template) and replace by Albanian for Song. Same with !PRAYER! (5 times)

Find !OPENING! and replace by whatever 'Opening Comments' currently are in Albanian. Same for !CONCLUSION! (2 times) and concluding commnents. I vaguely think those were changed as of 2020.

In line 428 of the COMBO_1 template change !TITLE! to whatever 'weekend meeting' should be. 

The date after both midweek and weekend meeting is retrieved by !DATE ddd, dd.MM.! in lines 82 and 428. This formats the date into dd.MM. which is not a normal representation of dates where I live. This is where you can change this. To e.g. dd-MM.

Finally: not shown in the picture, and rightly so, is the congregation name. You may already have found it on line 70, represented by !CONGREGATION_TITLE! It may need changing into the actual expression, because in English the word 'congregation' usually comes after the name of the congregation, but this is not the same in all languages.


https://www.theocbase.net/support-forum/post/1097-donations.html

For accessing the database my personal preference is http://sqlitebrowser.org/

For editing templates I like to use http://brackets.io/ 

 


more than a month ago
·
#6527
Accepted Answer
0
Votes
Undo

I do not see any song that changed, also the opening comments are in English, so I wonder if the screenshot belongs to the problem(s) you describe. Anyway:

Find all occurrences of !SONG! (exactly that, not anything else with song, there are 7 occurrences in the COMBO_1 template) and replace by Albanian for Song. Same with !PRAYER! (5 times)

Find !OPENING! and replace by whatever 'Opening Comments' currently are in Albanian. Same for !CONCLUSION! (2 times) and concluding commnents. I vaguely think those were changed as of 2020.

In line 428 of the COMBO_1 template change !TITLE! to whatever 'weekend meeting' should be. 

The date after both midweek and weekend meeting is retrieved by !DATE ddd, dd.MM.! in lines 82 and 428. This formats the date into dd.MM. which is not a normal representation of dates where I live. This is where you can change this. To e.g. dd-MM.

Finally: not shown in the picture, and rightly so, is the congregation name. You may already have found it on line 70, represented by !CONGREGATION_TITLE! It may need changing into the actual expression, because in English the word 'congregation' usually comes after the name of the congregation, but this is not the same in all languages.


https://www.theocbase.net/support-forum/post/1097-donations.html

For accessing the database my personal preference is http://sqlitebrowser.org/

For editing templates I like to use http://brackets.io/ 

 


more than a month ago
·
#6550
0
Votes
Undo

Thanks for much for your help with this i've managed to alter everything i need. There's one little thing extra im trying to change, its the phrase "Week Starting... " below the congregation name on the COMBO.htm. Any idea how i can alter that to the albanian version but it still add the week starting date for each week? 

Thanks again for all your help

more than a month ago
·
#6551
0
Votes
Undo

In the html replace !WEEKSTARTING! (not a shocking surprise ;-)) in line 72 with what would be the common expression in your language.


https://www.theocbase.net/support-forum/post/1097-donations.html

For accessing the database my personal preference is http://sqlitebrowser.org/

For editing templates I like to use http://brackets.io/ 

 


more than a month ago
·
#6552
0
Votes
Undo

I have tried this but it doesnt preserve the date next to it? I only get the phrase in albanian...

more than a month ago
·
#6553
0
Votes
Undo

Yes I would have thought you had figured that out. That is weird, though, I'll have a look later today. Make sure you do not delete anything else.


https://www.theocbase.net/support-forum/post/1097-donations.html

For accessing the database my personal preference is http://sqlitebrowser.org/

For editing templates I like to use http://brackets.io/ 

 


more than a month ago
·
#6554
0
Votes
Undo

I think I figured that out, and it does not make me happy... If you analyse it, everything on that line after !WEEKSTARTING! is to check if it is a special week and if so to print that exception. But there isn't any reference to a date. So the date itself is within the !WEEKSTARTING! placeholder. 

That is an unwelcome surprise. Here is the thing: you would be able to somehow calculate the startdate of the week, but I have no clue as to how to do those calculations.

I know who works with these template files, and I will ask him how difficult it would be to adapt this template, so that they become more flexible for use in other languages.


https://www.theocbase.net/support-forum/post/1097-donations.html

For accessing the database my personal preference is http://sqlitebrowser.org/

For editing templates I like to use http://brackets.io/ 

 


more than a month ago
·
#7713
0
Votes
Undo

@Richard,

it is a long while we discussed this. There is and there is not a solution. Not one that will automatically work for everyone, but one that everyone can tweak to use for himself. The one that is designing the templates found this.

Find the combo template. For now I assume you use combo1. Check the exact wording which comes out in English. For now I assume that is Week Starting

Copy that combo somehwere outside the template folder. (There are no permissions to change and save a template within that folder) Rename to combo3 or combo11 or whatever suits you. Open the template with a good text editor. CodeWriter in Windows 10, Notepad++, Brackets, Visual Studio Code. (NOT Notepad and certainly not Word.)

Create a  few extra lines between line 573 (which has </main>) and line 574 (which has </body>)

In the extra line type (or copy paste) the expression below, in which you replace 'TB text' by the text TB produces and which you looked up previously, and you replace 'your Albanian expression' with what it should be. The quotation marks must be left in place!!

If the Albanian expression comes after the date, this would only work if the TB UI language also has this. 

After making the changes save the new template and put it back into the folder you first got it from. You will be asked for Admin permissions to do that.

<script>document.body.innerHTML = document.body.innerHTML.replace('TB text', 'your Albanian expression');</script>

 

 


https://www.theocbase.net/support-forum/post/1097-donations.html

For accessing the database my personal preference is http://sqlitebrowser.org/

For editing templates I like to use http://brackets.io/ 

 


more than a month ago
·
#7941
0
Votes
Undo

I'm also struggling with translation on the combo_1 template, but only with the weekendmeeting. I'm unexperienced with htm coding. I have tried so alter the template, but with bad success. 

Before the recent update. The "conductor" was named "studieleder" in danish ... now it's tranlated til "Dirigent" wich is a conductor of an orchestra.

The circuit overseer is correctly translated in the midweekmeeting programme to "kredstilsynsmand" but ind the weekendmeeting, its not translated

When importing the midweekmeeting programme, I can type the correct tranlation-texts so it co-responds to the template ... is that possible for the weekendmeeting aswell?

kind Regards 

Morten Andersen

more than a month ago
·
#7942
0
Votes
Undo

All the localised expressions are not made by the TB team, but by translator volunteers. If they don't translate, TB defaults back to English. If they translate it wrong... Someone obviously accepted an automatic translation in one instance, and did not do a translation (yet) in another.

You do not have to understand html at all to correct this. The only thing is you need a good editor (Notepad++ is good enough), and also you need to realise that you cannot store within the template folder. So you take the template, copy it somewhere, then change it, and after ward put it back (preferably under a different name, see later)

Any template is full of references. !CO! picks up the local (Danish) translation for circuit overseer !CO_NAME! picks up his name which you entered.

So if in any template you find all instances of !CO! and replace that (also remove the exclamation marks) with Kredstilsynsmand, that is OK. Note that if you would change the language of TB, the flexibility is gone. So you may want to store the template as xxxx_Danish.htm or somehting like that.

To change the dirigent back to Studieleder, find all instances of !CONDUCTOR! and replace it. See attachment.

Don't forget to Save


https://www.theocbase.net/support-forum/post/1097-donations.html

For accessing the database my personal preference is http://sqlitebrowser.org/

For editing templates I like to use http://brackets.io/ 

 


  • Page :
  • 1
There are no replies made for this post yet.
Be one of the first to reply to this post!