Multi-language / URL aliases

Author Message

Michael Kress

Saturday 12 January 2008 3:37:02 pm

Hi, according to this page:
http://ez.no/doc/ez_publish/technical_manual/4_0/features/multi_language_support_for_url_aliases
I'd like to use urls of this form:

http://www.example.com/en/Company
http://www.example.com/en/Compagnie

How can I do this with ez publish?
I tried to set HostMatchMapItems in ./settings/override/site.ini.append.php like this but I didn't succeed:

HostMatchMapItems[]
HostMatchMapItems[]=admin.example.com;ezwebin_site_admin
HostMatchMapItems[]=www.example.com;ezwebin_site_user
HostMatchMapItems[]=www.example.com/de;ger
HostMatchMapItems[]=www.example.com/en;eng

I'm using version 4.0 under centos 5.1 (managed by ispconfig).
Thanks - Michael

Piotrek Karaƛ

Saturday 12 January 2008 10:32:32 pm

Hello Michael,

I don't think 'www.example.com/de' can be considered a host. Also, with the exception of some advanced matching techniques, you would need a clear siteaccess separation:

http://www.example.com/Company
http://www.example.de/Compagnie

or

http://www.example.com/en/Company
http://www.example.com/de/Compagnie

Then, each siteaccess would need a different default language set, to choose proper translation.

http://ez.no/doc/ez_publish/technical_manual/4_0/reference/configuration_files/site_ini/siteaccesssettings

Hope this helps a bit.

--
Company: mediaSELF Sp. z o.o., http://www.mediaself.pl
eZ references: http://ez.no/partners/worldwide_partners/mediaself
eZ certified developer: http://ez.no/certification/verify/272585
eZ blog: http://ez.ryba.eu

Michael Kress

Sunday 13 January 2008 3:52:03 am

Could you/someone give me a concrete example, please? I _was_ playing with the SiteAccessSettings section, but unfortunately I ended up in a kernel error (view doesn't exist). I also recreated all the aliases before by issuing

php bin/php/updateniceurls.php

Greg McAvoy-Jensen

Sunday 13 January 2008 7:59:54 am

It seems to me you might actually be looking for the uri method rather than host. If I were trying to do it, here's what I'd do to use:

http://www.example.com/en/Company
http://www.example.com/en/Compagnie

1. In the [SiteAccessSettings] of settings/override/site.ini.append.php,
MatchOrder=uri
(and comment out (with #) your HostMatchMapItems)

2. In the [RegionalSettings] of each settings/siteaccess/your_site_accesses, set these in the correct order (varies by site access):
SiteLanguageList[]
SiteLanguageList[]=eng-GB
SiteLanguageList[]=fre-FR
etc.--whatever your languages are

3. Rename your site access from eng to en if that's the way you'd like it displayed, and similarly for any other public siteaccesses.

4. Set up your translations for each page.

Granite Horizon, Certified Developer of eZ Publish Web Solutions
Provider of the SaaS Solution Granite Horizon In The Cloud | http://granitehorizon.com/cloud
http://granitehorizon.com | +1 916 647 6350 | California USA | @granitegreg
Blog: http://granitehorizon.com/blog

Andy Caiger

Monday 28 December 2009 6:15:02 am

I want to do is have the same URLs in all the different languages, basically turn off multilanguage URL aliases, or (to put it another way) force all siteaccesses to show the URL aliases for the main language. Is there a setting somewhere that will do this? Thanks!

EAB - Integrated Internet Success
Offices in England, France & China.
http://www.eab.co.uk http://www.eab-china.com http://www.eab-france.com

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 16:21:38
Script start
Timing: Jan 18 2025 16:21:38
Module start 'layout'
Timing: Jan 18 2025 16:21:38
Module start 'content'
Timing: Jan 18 2025 16:21:39
Module end 'content'
Timing: Jan 18 2025 16:21:39
Script end

Main resources:

Total runtime1.2378 sec
Peak memory usage4,096.0000 KB
Database Queries67

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0045 589.0313152.6250
Module start 'layout' 0.00450.0028 741.656339.4453
Module start 'content' 0.00731.2289 781.1016656.7813
Module end 'content' 1.23620.0015 1,437.882816.7891
Script end 1.2377  1,454.6719 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00320.2615160.0002
Check MTime0.00130.1085160.0001
Mysql Total
Database connection0.00060.046810.0006
Mysqli_queries1.178895.2333670.0176
Looping result0.00070.0529650.0000
Template Total1.203997.320.6019
Template load0.00210.168720.0010
Template processing1.201897.089020.6009
Template load and register function0.00020.012310.0002
states
state_id_array0.00120.098410.0012
state_identifier_array0.00190.149520.0009
Override
Cache load0.00200.1576430.0000
Sytem overhead
Fetch class attribute can translate value0.00060.050740.0002
Fetch class attribute name0.00090.076380.0001
XML
Image XML parsing0.00170.139740.0004
class_abstraction
Instantiating content class attribute0.00000.001580.0000
General
dbfile0.00110.0921310.0000
String conversion0.00000.000540.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
5content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
6content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
12content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
5content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
3content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 33
 Number of unique templates used: 7

Time used to render debug report: 0.0002 secs