Forums / Developer / Differences between host;uri and host_uri in MatchOrder ?

Differences between host;uri and host_uri in MatchOrder ?

Author Message

Jerome Despatis

Friday 01 July 2011 1:54:07 am

For now, I have a multilingual website, I wanted uri like domain.com/fr, domain.com/zh etc..

So I've used MatchOrder=host;uri, And i've renamed the default siteaccesses (coded on three characters by default), for example 'fre' to 'fr' and so on for all siteaccesses

Now, until eZ 4.5 (or 4.4, I can't remember), the MatchOrder=host_uri has appeared...

Anyone could explain me the difference between the both ? the advantages of host_uri in regards of host;uri in fact

Thanks

Jérôme Vieilledent

Friday 01 July 2011 5:30:38 am

Hi Jerome

The difference is in the way eZ Publish tries to figure out which siteaccess to use to handle the request.

  • host;uri will try first the host mode, and then the URI mode if the host mode failed
  • host_uri will take the 2 as a whole (host + URI at the same time)

Jerome Despatis

Friday 01 July 2011 7:30:06 am

Ok thanks I understand.

But it leads me to another question: I'd like to have the FrontEnd and the BackEnd multilingual for example, to fully understand

Here I definitely need host_uri I guess

So i do something like, for example:

MatchOrder=host_uri
HostUriMatchMapItems[]=adminezpublish11.poseidon.dev;;ezwebin_site_clean_admin
HostUriMatchMapItems[]=adminezpublish11.poseidon.dev;es;ezwebin_site_clean_admin
HostUriMatchMapItems[]=wwwezpublish11.poseidon.dev;en;en;end
HostUriMatchMapItems[]=wwwezpublish11.poseidon.dev;es;es;end

I go to http://adminezpublish11.poseidon.dev/es

I was thinking page would be exactly the same as http://adminezpublish11.poseidon.dev as same siteaccess is used

But I get indeed 'es' is an undefined module (kernel 20 error)

The logic is however good for FE

Any idea ?

eZ debug

Timing: Jan 18 2025 00:04:03
Script start
Timing: Jan 18 2025 00:04:03
Module start 'content'
Timing: Jan 18 2025 00:04:04
Module end 'content'
Timing: Jan 18 2025 00:04:04
Script end

Main resources:

Total runtime0.8890 sec
Peak memory usage4,096.0000 KB
Database Queries195

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0059 587.9531180.8203
Module start 'content' 0.00590.7372 768.7734520.9141
Module end 'content' 0.74310.1459 1,289.6875332.7109
Script end 0.8889  1,622.3984 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00420.4678210.0002
Check MTime0.00170.1857210.0001
Mysql Total
Database connection0.00090.098910.0009
Mysqli_queries0.812191.35281950.0042
Looping result0.00190.21491930.0000
Template Total0.864697.320.4323
Template load0.00210.237720.0011
Template processing0.862597.022220.4313
Template load and register function0.00020.019310.0002
states
state_id_array0.00110.121610.0011
state_identifier_array0.00090.105820.0005
Override
Cache load0.00180.2020340.0001
Sytem overhead
Fetch class attribute can translate value0.00130.149430.0004
Fetch class attribute name0.00180.199440.0004
XML
Image XML parsing0.00080.092930.0003
class_abstraction
Instantiating content class attribute0.00000.001640.0000
General
dbfile0.00780.8752280.0003
String conversion0.00000.000730.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
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
3content/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
1content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
2content/datatype/view/ezxmltags/strong.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/strong.tplEdit templateOverride template
2content/datatype/view/ezxmltags/li.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/li.tplEdit templateOverride template
1content/datatype/view/ezxmltags/ul.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/ul.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
2content/datatype/view/ezxmltags/link.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/link.tplEdit templateOverride template
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 20
 Number of unique templates used: 10

Time used to render debug report: 0.0002 secs