Individual Branded Pages

Topics: Customizing Orchard, General
Apr 13, 2015 at 6:30 PM
Hey all,

Looking for a little guidance and any thoughts you may have on this use-case.

I am working on a website for a travel agency. They have over 100 independent agents and would like to create branded "sites" for each of the agents that would just be a copy of the main site. So, for instance, would show the main site and the corporate branding. However, if you went to, you would see the same content but with Bill's branding and contact info.

I am thinking that each agent will actually be a user in the orchard site. That way they can use it for a company portal, too.

Any thoughts/suggestions on the best way to accomplish this?
Apr 13, 2015 at 7:22 PM
Edited Apr 13, 2015 at 7:23 PM
The way I have does it is to create a taxonomy called SiteArea and attach it to my part called PageMetadataPart, then use the value from that to render a different Less CSS file. i.e.
string area = ((IEnumerable<TermPart>)((dynamic)contentItem).PageMetadataPart.SiteArea.Terms).Single();    

if (WorkContext.CurrentCultureInfo().TextInfo.IsRightToLeft) {
    Style.Require(string.Format("site_{0}_rtl", area));
else {
    Style.Require(string.Format("site_{0}", area));
I will push the theme I have to a public repo at some point this week if that will help?
Apr 13, 2015 at 10:52 PM
Edited Apr 13, 2015 at 10:58 PM
Thanks for the reply!

I'm not sure I totally understand your strategy, but I'd love to look at the theme! Thanks.
Apr 13, 2015 at 11:14 PM
Hey Jetski5822, make that two of us ;) Basically, I'll be in need of such an implementation in the coming weeks with a collection of local community groups wishing the same style of reusability / replication. I won't hijack matt's thread by elaborating, but I'm also trying to conceptualize the best way to solve such a situation, too. Thanks Dyr
Apr 13, 2015 at 11:19 PM
No problem guys, its a client theme at the moment, so I will need to ACMEize it to remove client specific things text and colours.

Should be end of the week. N
Apr 14, 2015 at 10:29 AM
Okay, here you go.

I have removed all the client specific names etc, and made it for ACME Medical. However, Because I removed all styling, I have just dumped in a bootswatch I found so the colour scheme is a bit funky.

The theme is a WIP and has, at present:

1: RTL support
2: Ability to style different areas of the site by taxonomy
3: Taxonomy layer rule for sitearea('provider')
4: Bing SEO
5: Google SEO
6: Multi-Culture Theme Settings
7: Cookie Bar built in
8: External Link dialogs (this is important for the pharma industry)
9: Wordpress shortcodes for a bunch of things (Though, you will need to wait for me to upgrade tinymce for you to see them nicely surfaced in TinyMCE)
10: Footer all configurable from the Theme Settings admin
11: Uses LESS

Have a play, its more an example of what you can do.... and as always, PR are accepted :)

Oh and if you see something that's client specific... please let me know ASAP.

Apr 14, 2015 at 3:37 PM
Thanks a bunch!
Apr 16, 2015 at 1:30 AM
Yeah, Legendary Nick! I will have a play ASAP - thanks for you efforts - I'm sure I'll be able to learn a thing or two ;) Cheers
May 16, 2015 at 7:39 AM
Hmm, I hope I'm not being incredibly stupid – but here goes...with your example acme theme, will it work straight out of the box if I was to create a <page> with an <area> “Member” selected (also with a visually different site-member.css file to the default), so that when I browse to the newly created page – should it not alter/replace the default css with the site-member.css? If this is the case, for some reason - referring to the code in Views > Resources.html - "WorkContext.IsMemberRequest()" never returns "true" with the pages I'm creating with Member selected, or any of the default site areas for that matter?
Or do I have your codes intent completely wrong blush? Any assistance would be great, as I’m stumped – big thanks, Liv.
PS> said above to let you know of any residual company left overs - so pretty non threatening to say the least, I know - but, the favicon is still there ;)
May 17, 2015 at 7:57 PM
Hi Liv,

Could you raise you question on Github? (I tend not to look at codeplex much)

If you raise it, I will try and answer straight away.

FYI - Thanks for the icon heads up,

Cheers, Nick