Forums / Developer / HostMatchMapItems - default siteaccess / Comment49183
Clemens T
Tuesday 04 March 2008 5:55:03 am
Heya Andre, that helped a lot... I got it!
[SiteAccessSettings] CheckValidity=false AvailableSiteAccessList[]=en AvailableSiteAccessList[]=nl MatchOrder=uri;host; HostMatchType=map HostMatchMapItems[]=www.myhost.nl;en HostMatchMapItems[]=myhost.nl;en RemoveSiteAccessIfDefaultAccess=enabled #did not enable forcevirtualhost, because then it breaks my index.php/mysiteacces/ bookmarks (and other people's) - index.php is not a module #ForceVirtualHost=true
And the following .htaccess file in my root web folder:
Options +FollowSymlinks RewriteEngine On RewriteRule ^var/storage/.* - [L] RewriteRule ^var/[^/]+/storage/.* - [L] RewriteRule ^var/cache/texttoimage/.* - [L] RewriteRule ^var/[^/]+/cache/texttoimage/.* - [L] RewriteRule ^design/.* - [L] #RewriteRule ^design/[^/]+/(stylesheets|images|javascript)/.* - [L] #RewriteRule ^design/[^/]+/(stylesheets|images|javascript)/.* - [L] RewriteRule ^share/icons/.* - [L] RewriteRule ^sitemaps/.* - [L] RewriteRule ^extension/[^/]+/design/[^/]+/(stylesheets|images|javascripts|javascript?)/.* - [L] RewriteRule ^packages/styles/.+/(stylesheets|images|javascript)/[^/]+/.* - [L] RewriteCond $1 !^index.php$ RewriteRule (.*) /index.php DirectoryIndex index.php
This works great! Exactly what I wanted. My old links are still valid, but my new links are without the index.php and the default siteaccess.
Also in my templates I used the <b>|ezroot</b> operator instead of <b>|ezurl</b>. This gets rid of the index.php in the urls. (And because I didn't set ForceVirtualHost=true, this is needed.)
Kudos+1 for you hehe. When is there going to be a kudos system (or something similar) on ez.no?