Forums / Extensions / Overriding standard translation with a translation extension

Overriding standard translation with a translation extension

Author Message

Niko Goers

Wednesday 16 May 2007 4:04:26 am

Hi,

i want to override one part of the original translation with a translation extension.

<b>My extensionfolder:</b> extension/my_extension/translations/ger-DE/translation.ts

<b>translation.ts:</b>

<context>
    <name>design/standard/content/tipafriend</name>
    <message>
        <source>Tip a friend</source>
        <translation>Weiterempfehlen</translation>
    </message>
</context>

<b>site.ini.append.php in settings/override:</b>

[...]
[ExtensionSettings]
[...]
ActiveExtensions[]=my_extension
[...]

<b>site.ini.append.php in settings/siteaccess/my_siteacces:</b>

[...]
[ExtensionSettings]
ActiveAccessExtensions[]=my_extension
[...]
[RegionalSettings]
Locale=ger-DE
ContentObjectLocale=ger-DE
SiteLanguageList[]=ger-DE
TextTranslation=enabled
TranslationExtensions[]=my_extension
[...]

Why does it not work?

Thank you for your help.

eZ Publish partner - http://www.all2e.com
http://share.ez.no/directory/companies/all2e-gmbh
http://ez.no/Partners/all2e-GmbH

Lords of Heaven - http://www.LoH-Gilde.de (Created with eZ Publish)
German online gaming guild

About me - http://www.NikoGoers.de

My roadmap, +1 are welcome: http://share.ez.no/community/roadmap/10889

Niko Goers

Saturday 19 May 2007 8:47:19 am

Any Ideas?

eZ Publish partner - http://www.all2e.com
http://share.ez.no/directory/companies/all2e-gmbh
http://ez.no/Partners/all2e-GmbH

Lords of Heaven - http://www.LoH-Gilde.de (Created with eZ Publish)
German online gaming guild

About me - http://www.NikoGoers.de

My roadmap, +1 are welcome: http://share.ez.no/community/roadmap/10889

Pascal Specht

Thursday 28 June 2007 12:59:34 am

Hi Niko,

Did you get it working? I'm struggling with the same problem: I want to change some of the translations in the translation.ts file that cames with the ezwebin interface, and want to apply my change without having to touch that particular file. I'd prefer overriding the translation.ts in an intelligent way, so that I don't have to start all over at the next release.

Any suggestions are welcome.

Pascal

Matthew Carroll

Tuesday 10 July 2007 1:44:34 pm

You need to include the following in extension/my_extension/settings/site.ini.append.php

[RegionalSettings]
TranslationExtensions[]=my_extension

...I think maybe that line doesn't work if you have it in settings/siteaccess/my_siteaccess/site.ini.append.php. Without testing I'm not 100% sure, but I set this up for one of my sites last year, and that's the setup I have now which is working.

Matthew

http://carroll.org.uk

Pascal Specht

Wednesday 11 July 2007 9:21:49 am

Just for anyone else struggling with this:

Do <b>NOT</b> use the ezwebin admin HTML interface to enable/disable extensions! it writes the extension list back in an arbitrary order. To get it working, extensions that overwrite others should be included <b>before</b> their original ones, and the only way to be sure about this is to manually modify the site.ini.overwrite.php file, not through the webmin.

Pascal

eZ debug

Timing: Jan 29 2025 13:31:06
Script start
Timing: Jan 29 2025 13:31:06
Module start 'content'
Timing: Jan 29 2025 13:31:06
Module end 'content'
Timing: Jan 29 2025 13:31:06
Script end

Main resources:

Total runtime0.1257 sec
Peak memory usage2,048.0000 KB
Database Queries141

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0052 588.1875180.7969
Module start 'content' 0.00520.0044 768.9844102.0078
Module end 'content' 0.00960.1159 870.9922530.9219
Script end 0.1256  1,401.9141 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00332.6204200.0002
Check MTime0.00131.0110200.0001
Mysql Total
Database connection0.00070.534710.0007
Mysqli_queries0.086869.06791410.0006
Looping result0.00090.73811390.0000
Template Total0.115792.010.1157
Template load0.00060.499010.0006
Template processing0.115091.537910.1150
Override
Cache load0.00040.351810.0004
Sytem overhead
Fetch class attribute can translate value0.00050.395610.0005
XML
Image XML parsing0.00020.175710.0002
General
dbfile0.00544.2695200.0003
String conversion0.00000.004030.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs