Embedded object translation problem

Author Message

Lo' F.

Wednesday 17 November 2010 2:20:35 pm

Hi!

I have a frontpage object embedded inside another frontpage.

Added a new translation for this included object, but when browsing the page in another language, the main frontpage is right in the current language version while this embedded object keeps having the original language. A translated version of an object should not be taken automatically?

Launching $object|attribute(show), I get this outcome

Attribute Type Value
...    
name string 'Object Title in English'
...    
>name string 'Object Title in Italian'
>version_name string 'Object Title in English'
...    
class_name string 'Frontpage'
content_class object[eZContentClass] Object
...    
>prioritized_languages_js_array string '[ { locale: 'eng-GB', name: 'English (United Kingdom)' } ]'
...    
>top_priority_language_locale string 'eng-GB'
...    
>default_language string 'eng-GB'
...    
>current_language string 'ita-IT'
...    
>initial_language_code string 'ita-IT'
...    
default_language string 'eng-GB'
...    
current_language string 'eng-GB'
...    
>name string 'English (United Kingdom)'
>locale string 'eng-GB'
...    
initial_language object[eZContentLanguage] Object
>name string 'Italiano'
>locale string 'ita-IT'
...    
initial_language_code string 'ita-IT'
available_languages array Array(1)
>0 string 'eng-GB'
language_codes array Array(1)
>0 string 'eng-GB'
language_js_array string '[ { locale: 'eng-GB', name: 'English (United Kingdom)' } ]'
languages array Array(1)
>eng-GB object[eZContentLanguage] Object
all_languages array Array(2)
>eng-GB object[eZContentLanguage] Object
>ita-IT object[eZContentLanguage] Object
...    

?!

loredanaebook.it

Lo' F.

Wednesday 17 November 2010 3:38:51 pm

..Oh, leave it..!

The problem was that in the template line.tpl the name of the object, which is actually the only part being showed inside the frontpage. was recalled in this way..

{$object.main_node.name}

which obviously refers to its original version name, instead of this other way...

{$object.name}

loredanaebook.it

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 10:30:32
Script start
Timing: Jan 18 2025 10:30:32
Module start 'layout'
Timing: Jan 18 2025 10:30:32
Module start 'content'
Warning: PHP: E_DEPRECATED Jan 18 2025 10:30:33
trim(): Passing null to parameter #1 ($string) of type string is deprecated in /home/ze/public_html/share.se7enx.com/var/community/cache/template/compiled/table-02cf899a6d707917c58210ed54ffe2ff.php on line 147
Timing: Jan 18 2025 10:30:33
Module end 'content'
Timing: Jan 18 2025 10:30:33
Script end

Main resources:

Total runtime0.8341 sec
Peak memory usage4,096.0000 KB
Database Queries52

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0087 587.9375152.6250
Module start 'layout' 0.00870.0048 740.562539.4531
Module start 'content' 0.01350.8191 780.0156580.7109
Module end 'content' 0.83260.0014 1,360.726620.3672
Script end 0.8340  1,381.0938 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00390.4695160.0002
Check MTime0.00140.1725160.0001
Mysql Total
Database connection0.00160.196410.0016
Mysqli_queries0.679281.4385520.0131
Looping result0.00050.0585500.0000
Template Total0.795395.420.3977
Template load0.00220.262620.0011
Template processing0.793195.092020.3966
Template load and register function0.00010.012010.0001
states
state_id_array0.00090.102310.0009
state_identifier_array0.00080.093320.0004
Override
Cache load0.00240.28291910.0000
Sytem overhead
Fetch class attribute can translate value0.00090.111810.0009
Fetch class attribute name0.00110.131630.0004
XML
Image XML parsing0.00050.054010.0005
class_abstraction
Instantiating content class attribute0.00000.001240.0000
General
dbfile0.00100.1205160.0001
String conversion0.00000.001340.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
2content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
2content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
6content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
2content/datatype/view/ezxmltags/emphasize.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/emphasize.tplEdit templateOverride template
1content/datatype/view/ezxmltags/th.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/th.tplEdit templateOverride template
43content/datatype/view/ezxmltags/tr.tpl<No override>extension/community/design/community/templates/content/datatype/view/ezxmltags/tr.tplEdit templateOverride template
42content/datatype/view/ezxmltags/td.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/td.tplEdit templateOverride template
1content/datatype/view/ezxmltags/table.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/table.tplEdit templateOverride template
2content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 103
 Number of unique templates used: 11

Time used to render debug report: 0.0002 secs