Alternate Content Panes

This is an open forum for any mojoPortal topics that don't fall into the other categories.

This thread is closed to new posts. You must sign in to post in the forums.
3/5/2010 9:40:31 PM
Gravatar
Total Posts 2188

Alternate Content Panes

Hey Joe,

The doc for Alternate Content Panes (http://www.mojoportal.com/morethan3contentpanels.aspx) suggests that one should use divAlt1 as the ID of the asp:panel for altContent1 and divAltContent2 as the ID for the asp:panel for altContent2. I have used divAltContent1 instead of divAlt1 in the past and everything seemed to work fine but I just wanted to check with you to see if the ID of the asp:panel matters at all.

Thanks,
Joe D.

3/6/2010 6:46:53 AM
Gravatar
Total Posts 18439

Re: Alternate Content Panes

Hi Joe,

It may work somewhat without those as long as the content place holders have the correct ids, but there is some logic in the code behind for layout.master that is looking for those divs with those ids. The logic is not doing anything really important, it just adds a css class "cmszone" to the divs and this class is not currently used in any included skins so it really isn't very important. Basically all of the content wrapper divs have this cmszone class so it could be used to apply styles on all content regions. So really the cmszone class is designed especially for the case where you are using these 2 extra regions and you might need a way to apply styles that affect all of them. Of course if you use a different id for the alt divs then you could manually add that css class if you wanted to.

<asp:ContentPlaceHolder ID="altContent1" runat="server"></asp:ContentPlaceHolder>

<asp:ContentPlaceHolder ID="altContent2" runat="server"></asp:ContentPlaceHolder>

Let me emphasize for other readers that though the div id is not that important for the 2 extra content sections the ids for divLeft, divRight, and divCenter are very important. For consistency I think it is better if people just think of them all as important.

Best,

Joe

You must sign in to post in the forums. This thread is closed to new posts.