Feb 12, 2011 at 8:20 PM
Edited Feb 12, 2011 at 8:20 PM
Extended the logic for my SiteMapProvider so it now correctly handles multiple websites, also updated CompositeC1Contrib to include these changes.
Say we have the following structure in C1
- Website1 (hostname ws1.com)
- Website2 (hostname ws2.com)
With the newest additions its possible to access all the necessary pages like this
And most importanly, its NOT possible to do this
Furthermore the SiteMap provider is aware of which website we're browsing so stuff like SiteMap.RootNode will point to the correct page node (Website1 or Website2) in C1. All this also works fine with languages, where the language-code is just appended just
after the hostname, but before page urls as usual.
And last, but not least, while the above schema is preferred when the customers are browsing the website, it can be annoying when editing pages i C1, not being able to preview across website boundaries. I've therefor included logic to allow cross-site requests
when dataScope=administrated. This means that this is possible
And all rendered urls on the page reflect this as well, when viewing pages in the administrated datascope.