How to force content creation language in BO?

Author Message

Nicolas Panau

Wednesday 13 July 2011 3:29:14 am

Hi,

I Have a monolingual site (french), and I'm looking for a way to skip the "choose language" screen.
I haven't found any params yet in ini files...
Any clue anyone?

Thanks

www.umanit.fr

Damien Pobel

Wednesday 13 July 2011 4:39:42 am

Hi Nicolas,

This is a typical issue for mono language site not in eng-GB and I'm afraid there's no easy solution currently.

The cleanest solution is probably to remove the eng-GB language through /content/translations in the admin interface. But if I remember correctly, to be able to do this, you have to translate all existing objects and classes in fre-FR and then remove the eng-GB versions for each... On an existing project this can be quite long but I think it should be feasible through a script if you consider that not yet translated objects/classes should be the same in fre-FR.

Cheers

Damien
Planet eZ Publish.fr : http://www.planet-ezpublish.fr
Certification : http://auth.ez.no/certification/verify/372448
Publications about eZ Publish : http://pwet.fr/tags/keywords/weblog/ez_publish

Thiago Campos Viana

Wednesday 13 July 2011 4:48:53 am

Override the related template and add this field:

<input type="hidden" name="ContentObjectLanguageCode" value="{ezini( 'RegionalSettings', 'ContentObjectLocale', 'site.ini')}" />

eZ Publish Certified Developer: http://auth.ez.no/certification/verify/376924

Twitter: http://twitter.com/tcv_br

Nicolas Panau

Wednesday 13 July 2011 4:58:08 am

@Damien thanks, i was afraid of this answer (i've seen the 'eng-GB' hardcoded somewhere :-s). Think i should'nt have created the french language, it would have been simplier. Anyway, that's a new website, i might restart the install ^^'

@Thiago that's a solution, but i don't like overriding BO functions, specially "the create here" drop down (which has discutions about usability if i remeber correctly).

Anyway, i have my answer, thanks! :-)

www.umanit.fr

Hamdi Laadhari

Wednesday 13 July 2011 6:05:32 am

eng-GB is kind of hardcoded into eZ Publish kernel. It a strange behavior, we have to do with it.

Certified eZ Publish Entreprise 4.5
http://www.laadhari.fr

Gaetano Giunta

Thursday 14 July 2011 5:24:22 am

eng-GB is not "hardcoded" in eZ. It's just that the default content classes are all created in english, and you have to de-translate them before english can be deactivated. Starting with a very empty content setup is your best bet (get no demo content from packages or start the db using the sql provided with sources instead of using the setup wizard)

Principal Consultant International Business
Member of the Community Project Board

Nicolas Panau

Monday 18 July 2011 8:22:57 am

Thanks Gaetano, it works perfectly! (delete all class translations, and then delete English Language).
You saved me hours ;)

www.umanit.fr

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 17 2025 23:40:17
Script start
Timing: Jan 17 2025 23:40:17
Module start 'layout'
Timing: Jan 17 2025 23:40:17
Module start 'content'
Timing: Jan 17 2025 23:40:18
Module end 'content'
Timing: Jan 17 2025 23:40:18
Script end

Main resources:

Total runtime1.3034 sec
Peak memory usage4,096.0000 KB
Database Queries75

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0070 589.1563152.6406
Module start 'layout' 0.00700.0033 741.796939.4844
Module start 'content' 0.01031.2915 781.2813713.2656
Module end 'content' 1.30180.0016 1,494.546916.1250
Script end 1.3034  1,510.6719 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00340.2617160.0002
Check MTime0.00140.1039160.0001
Mysql Total
Database connection0.00080.064110.0008
Mysqli_queries1.230394.3901750.0164
Looping result0.00080.0623730.0000
Template Total1.261096.720.6305
Template load0.00240.183120.0012
Template processing1.258696.561320.6293
Template load and register function0.00020.014310.0002
states
state_id_array0.00150.117510.0015
state_identifier_array0.00110.083120.0005
Override
Cache load0.00230.1734330.0001
Sytem overhead
Fetch class attribute can translate value0.00080.063550.0002
Fetch class attribute name0.00110.0872110.0001
XML
Image XML parsing0.00430.327850.0009
class_abstraction
Instantiating content class attribute0.00000.0017130.0000
General
dbfile0.00450.3476340.0001
String conversion0.00000.000740.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
6content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
7content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
8content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
2content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1content/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: 26
 Number of unique templates used: 7

Time used to render debug report: 0.0002 secs