Information on Sueetie's support for theme-based Master pages.
Theming Freedom
Adding support for theme-based and dynamically-assigned Master pages enables Web Designers to create Sueetie Community themes with complete freedom, as the earlier shared Master Page model is no more. All master pages are located in their application-specific location, distinct from the master pages of other themes. In some cases, not sharing is good. heh.
The Olden Days of the Shared Master Page Model and Today¶
Root Web AreaWith the shared master page model the root web area - that is, website content not in one of the community applications - we assigned either sueetie.master or alternate.master as the page's master page. These files were shared by all themes and located in a common /masters folder.
Master assignment of custom pages is now dynamic and each theme's master files are stored separately in /masters/THEME.BlogsSueetie adheres to BlogEngine.NET's native theming model where each Site.Master page is located in its /blog/themes/THEME folder. No change here.
ForumIn the shared master page model, a single Forum.Master page was located in the forum application root directory for all themes to share or overwrite, whatever their pleasure. Now each theme's Forum.Master page is located in its /forum/masters/THEME folder.
Media GallerySimilar to the forums shared master page logic, a single Media.Master page was located in the Gallery Server Pro application root for all themes to share. Each theme Media.Master page is located in /media/masters/THEME.
WikiScrewTurn Wiki uses two master pages: MasterPage.master and MasterPageSA.master (SA - standalone) in the application root. Substantial logic and relative pathing made the /wiki/masters/THEME approach problematic, so Sueetie supports multiple ScrewTurn master pages by theme name in the Web Application root, deriving from MasterPage.master.cs and MasterPageSA.master.cs respectively. For instance, for a theme named "ROCKET" these master page names would be Rocket.master and RocketSA.master.
Administration AreaIn the past all Sueetie Administration pages were hard-coded to use the original Lollipop theme. The Administration area theme is now easily changed by updating the Core AdminTheme property in the /Sueetie.config file.
An Example of Dynamic Master Page Assignment
Dynamic Master Page assignment is particularly useful for custom applications that are outside of one of the Community Applications. To assign a master page on-the-fly on a custom non-application page, inherit from the SueetieBaseThemedPage instead of SueetieBasePage. Below is what the SueetieBaseThemedPage looks like.

Then in the web page constructor specify the Master Page you wish to use for the SueetieMasterPage property. If no SueetieMasterPage is assigned, the default master page /masters/THEME/sueetie.master is used. Below demonstrates how the login page now loads the alternate.master page whereas in the past it was hard-coded in the .ASPX Page directive. Remember that Sueetie uses a Website Project model, so the Constructor() codebehind can be changed in notepad if you want to use a master page other than alternate.master.
Top