Tuesday, February 19, 2013

Making SharePoint Responsive Starting with the MasterPage

Let's start making a sharepoint site responsive! We'll start with modifications to the masterpage. Kyle Schaeffer has done a lot of groundwork and was a jumping off point for us. But we have slowly added in server side controls to help us with our payload.

As a cautionary note, none of this work on responsive is live on the internets yet, we're still building and changing things. I will come back and update any code pages with things we learn in the future. For newbies, start with Kyle, he's great. There are some custom controls in use that are live and I'll be sure to note that when I got into them in depth.

This is a huge and ugly paste. But see below for what we have come up with so far. Summary: we're rewriting the navigation control to output minimal markup. We're restricting the form from rendering any of the sharepoint javascript/css/items for anonymous users (as we use sharepoint for our front facing publishing sites). We are concatenating and minifying all of the javascript and CSS we are including. For each custom control on this page, I'll write a blog post specifically covering it. There was one other developer heavily involved at the beginning of this project(who has since moved to another place of employment) so it's possible that I'm missing some attribution (at least on the restricted render form). I apologize to those SharePointers on the web who we may have borrowed from and not attributed the work to. I worry about this.

We have a project called XXX.Optimization that includes a bunch of controls and handlers to format sharepoint's markup and rendering. I'm going to be walking through that project and sharing the work we did there. I will throw the whole thing up on git at some point shortly. And, as I figure out how blogspot deals with code chunks, hopefully the formatting will improve. Check back next time for the restricted render form.

The masterpage in it's glory.

1:  <%@ Master language="C#" %>  
2:  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">  
3:  <%@ Import Namespace="Microsoft.SharePoint" %>  
4:  <%@ Register Tagprefix="SharePoint" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>  
5:  <%@ Register Tagprefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages" Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>  
6:  <%@ Register TagPrefix="wssuc" TagName="Welcome" src="~/_controltemplates/Welcome.ascx" %>  
7:  <%@ Register TagPrefix="wssuc" TagName="MUISelector" src="~/_controltemplates/MUISelector.ascx" %>  
8:  <%@ Register Tagprefix="PublishingWebControls" Namespace="Microsoft.SharePoint.Publishing.WebControls" Assembly="Microsoft.SharePoint.Publishing, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111blorp" %>   
9:  <%@ Register Tagprefix="PublishingNavigation" Namespace="Microsoft.SharePoint.Publishing.Navigation" Assembly="Microsoft.SharePoint.Publishing, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce1blorp" %>  
10:  <%@ Register Tagprefix="xxx" Namespace="XXX.SharePoint.WebControls" Assembly="XXX.SharePoint.WebControls, Version=0.9.0.5, Culture=neutral, PublicKeyToken=fe920e10blorp"%>  
11:  <%@ Register Tagprefix="xxxOpt" Namespace="XXX.SharePoint.Optimization" Assembly="XXX.SharePoint.Optimization, Version=1.0.0.0, Culture=neutral, PublicKeyToken=a667f938c10blorp"%>  
12:  <%@ Register Tagprefix="xxxNav" Namespace="XXX.SharePoint.Navigation" Assembly="XXX.SharePoint.Navigation, Version=1.0.0.0, Culture=neutral, PublicKeyToken=a80c4cc1e1blorp"%>  
13:  <!DOCTYPE html>  
14:  <html lang="en">  
15:  <head runat="server">  
16:       <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"/>  
17:       <meta name="viewport" content="width=device-width"/>  
18:       <SharePoint:RobotsMetaTag runat="server"/>  
19:       <title><xxx:MetaTitle runat="server" ID="titleControl" __designer:Preview="Library" __designer:Values="&lt;P N='ID' T='titleControl' /&gt;&lt;P N='Page' ID='1' /&gt;&lt;P N='TemplateControl' ID='2' /&gt;&lt;P N='AppRelativeTemplateSourceDirectory' R='-1' /&gt;"/></title>  
20:       <link type="text/css" rel="stylesheet" href="http://fonts.googleapis.com/css?family=Source+Sans+Pro:400,600,400italic,600italic|Open+Sans+Condensed:300,700,300italic"/>  
21:       <SharePoint:SPSecurityTrimmedControl runat="server" AuthenticationRestrictions="AuthenticatedUsersOnly">  
22:            <SharePoint:CssLink runat="server" Version="4"/>  
23:            <SharePoint:Theme runat="server"/>  
24:            <SharePoint:ULSClientConfig runat="server"/>  
25:            <script type="text/javascript">  
26:            var _fV4UI = true;  
27:            </script>  
28:            <SharePoint:ScriptLink language="javascript" name="core.js" OnDemand="true" runat="server"/>  
29:            <SharePoint:CssRegistration name="<% $SPUrl:~sitecollection/Style Library/XXX/responsive.css %>" After="corev4.css" runat="server"/>  
30:            <SharePoint:CustomJSUrl runat="server"/>  
31:            <SharePoint:SoapDiscoveryLink runat="server"/>  
32:            <asp:ContentPlaceHolder id="PlaceHolderAdditionalPageHead" runat="server"/>  
33:            <SharePoint:DelegateControl runat="server" ControlId="AdditionalPageHead" AllowMultipleControls="true"/>  
34:            <SharePoint:SPShortcutIcon runat="server" IconUrl="/_layouts/images/favicon.ico"/>  
35:            <asp:ContentPlaceHolder id="PlaceHolderBodyAreaClass" runat="server"/>  
36:            <asp:ContentPlaceHolder id="PlaceHolderTitleAreaClass" runat="server"/>  
37:            <SharePoint:SPPageManager runat="server"/>  
38:            <SharePoint:SPHelpPageComponent Visible="false" runat="server"/>  
39:            <style type="text/css">html {overflow:hidden;}</style> </SharePoint:SPSecurityTrimmedControl>  
40:  </head>  
41:  <body onload="if (typeof(_spBodyOnLoadWrapper) != 'undefined') _spBodyOnLoadWrapper();" class="v4master no-js theme-xxx-blue1">  
42:       <xxxOpt:RestrictedRenderForm runat="server" onsubmit="if (typeof(_spFormOnSubmitWrapper) != 'undefined') {return _spFormOnSubmitWrapper();} else {return true;}" ControlsToRender="workspace"><asp:ScriptManager id="ScriptManager" runat="server" EnablePageMethods="false" EnablePartialRendering="true" EnableScriptGlobalization="false" EnableScriptLocalization="true" /><WebPartPages:SPWebPartManager runat="server"/>  
43:       <SharePoint:SPNoScript runat="server"/>  
44:       <SharePoint:DelegateControl runat="server" ControlId="GlobalNavigation"/><!-- **************************************************************** --><!-- BEGIN RIBBON --><div id="s4-ribbonrow" class="s4-pr s4-ribbonrowhidetitle"><div id="s4-ribboncont">  
45:            <SharePoint:SPRibbon runat="server" PlaceholderElementId="RibbonContainer" CssFile=""><SharePoint:SPRibbonPeripheralContent runat="server" Location="TabRowLeft" CssClass="ms-siteactionscontainer s4-notdlg"><span class="ms-siteactionsmenu" id="siteactiontd"><SharePoint:SiteActions runat="server" accesskey="<%$Resources:wss,tb_SiteActions_AK%>" id="SiteActionsMenuMain" PrefixHtml="" SuffixHtml="" MenuNotVisibleHtml="&amp;nbsp;"><CustomTemplate>  
46:                                               <SharePoint:FeatureMenuTemplate runat="server" FeatureScope="Site" Location="Microsoft.SharePoint.StandardMenu" GroupId="SiteActions" UseShortId="true">  
47:                                                    <SharePoint:MenuItemTemplate runat="server" id="MenuItem_EditPage" Text="<%$Resources:wss,siteactions_editpage%>" Description="<%$Resources:wss,siteactions_editpagedescriptionv4%>" ImageUrl="/_layouts/images/ActionsEditPage.png" MenuGroupId="100" Sequence="110" ClientOnClickNavigateUrl="javascript:ChangeLayoutMode(false);"/>  
48:                                                    <SharePoint:MenuItemTemplate runat="server" id="MenuItem_TakeOffline" Text="<%$Resources:wss,siteactions_takeoffline%>" Description="<%$Resources:wss,siteactions_takeofflinedescription%>" ImageUrl="/_layouts/images/connecttospworkspace32.png" MenuGroupId="100" Sequence="120"/>  
49:                                                    <SharePoint:MenuItemTemplate runat="server" id="MenuItem_CreatePage" Text="<%$Resources:wss,siteactions_createpage%>" Description="<%$Resources:wss,siteactions_createpagedesc%>" ImageUrl="/_layouts/images/NewContentPageHH.png" MenuGroupId="200" Sequence="210" UseShortId="true" ClientOnClickScriptContainingPrefixedUrl="if (LaunchCreateHandler('Page')) { OpenCreateWebPageDialog('~site/_layouts/createwebpage.aspx') }" PermissionsString="AddListItems, EditListItems" PermissionMode="All" />  
50:                                                    <SharePoint:MenuItemTemplate runat="server" id="MenuItem_CreateDocLib" Text="<%$Resources:wss,siteactions_createdoclib%>" Description="<%$Resources:wss,siteactions_createdoclibdesc%>" ImageUrl="/_layouts/images/NewDocLibHH.png" MenuGroupId="200" Sequence="220" UseShortId="true" ClientOnClickScriptContainingPrefixedUrl="if (LaunchCreateHandler('DocLib')) { GoToPage('~site/_layouts/new.aspx?FeatureId={00bfea71-e717-4e80-aa17-d0c71b360101}&amp;ListTemplate=101') }" PermissionsString="ManageLists" PermissionMode="Any" VisibilityFeatureId="00BFEA71-E717-4E80-AA17-D0C71B360101" />  
51:                                                    <SharePoint:MenuItemTemplate runat="server" id="MenuItem_CreateSite" Text="<%$Resources:wss,siteactions_createsite%>" Description="<%$Resources:wss,siteactions_createsitedesc%>" ImageUrl="/_layouts/images/newweb32.png" MenuGroupId="200" Sequence="230" UseShortId="true" ClientOnClickScriptContainingPrefixedUrl="if (LaunchCreateHandler('Site')) { STSNavigate('~site/_layouts/newsbweb.aspx') }" PermissionsString="ManageSubwebs,ViewFormPages" PermissionMode="All" />  
52:                                                    <SharePoint:MenuItemTemplate runat="server" id="MenuItem_Create" Text="<%$Resources:wss,siteactions_create%>" Description="<%$Resources:wss,siteactions_createdesc%>" MenuGroupId="200" Sequence="240" UseShortId="true" ClientOnClickScriptContainingPrefixedUrl="if (LaunchCreateHandler('All')) { STSNavigate('~site/_layouts/create.aspx') }" PermissionsString="ManageLists, ManageSubwebs" PermissionMode="Any" />  
53:                                                    <SharePoint:MenuItemTemplate runat="server" id="MenuItem_ViewAllSiteContents" Text="<%$Resources:wss,quiklnch_allcontent%>" Description="<%$Resources:wss,siteactions_allcontentdescription%>" ImageUrl="/_layouts/images/allcontent32.png" MenuGroupId="300" Sequence="302" UseShortId="true" ClientOnClickNavigateUrl="~site/_layouts/viewlsts.aspx" PermissionsString="ViewFormPages" PermissionMode="Any" />  
54:                                                    <SharePoint:MenuItemTemplate runat="server" id="MenuItem_EditSite" Text="<%$Resources:wss,siteactions_editsite%>" Description="<%$Resources:wss,siteactions_editsitedescription%>" ImageUrl="/_layouts/images/SharePointDesigner32.png" MenuGroupId="300" Sequence="304" UseShortId="true" ClientOnClickScriptContainingPrefixedUrl="EditInSPD('~site/',true);" PermissionsString="AddAndCustomizePages" PermissionMode="Any"/>  
55:                                                    <SharePoint:MenuItemTemplate runat="server" id="MenuItem_SitePermissions" Text="<%$Resources:wss,people_sitepermissions%>" Description="<%$Resources:wss,siteactions_sitepermissiondescriptionv4%>" ImageUrl="/_layouts/images/Permissions32.png" MenuGroupId="300" Sequence="310" UseShortId="true" ClientOnClickNavigateUrl="~site/_layouts/user.aspx" PermissionsString="EnumeratePermissions" PermissionMode="Any"/>  
56:                                                    <SharePoint:MenuItemTemplate runat="server" id="MenuItem_Settings" Text="<%$Resources:wss,settings_pagetitle%>" Description="<%$Resources:wss,siteactions_sitesettingsdescriptionv4%>" ImageUrl="/_layouts/images/settingsIcon.png" MenuGroupId="300" Sequence="320" UseShortId="true" ClientOnClickNavigateUrl="~site/_layouts/settings.aspx" PermissionsString="EnumeratePermissions,ManageWeb,ManageSubwebs,AddAndCustomizePages,ApplyThemeAndBorder,ManageAlerts,ManageLists,ViewUsageData" PermissionMode="Any" />  
57:                                                    <SharePoint:MenuItemTemplate runat="server" id="MenuItem_CommitNewUI" Text="<%$Resources:wss,siteactions_commitnewui%>" Description="<%$Resources:wss,siteactions_commitnewuidescription%>" ImageUrl="/_layouts/images/visualupgradehh.png" MenuGroupId="300" Sequence="330" UseShortId="true" ClientOnClickScriptContainingPrefixedUrl="GoToPage('~site/_layouts/prjsetng.aspx')" PermissionsString="ManageWeb" PermissionMode="Any" ShowOnlyIfUIVersionConfigurationEnabled="true" />  
58:                                               </SharePoint:FeatureMenuTemplate>  
59:                                          </CustomTemplate>  
60:                                      </SharePoint:SiteActions></span><asp:ContentPlaceHolder id="PlaceHolderGlobalNavigation" runat="server"><SharePoint:PopoutMenu runat="server" ID="GlobalBreadCrumbNavPopout" IconUrl="/_layouts/images/fgimg.png" IconAlt="<%$Resources:wss,master_breadcrumbIconAlt%>" IconOffsetX=0 IconOffsetY=112 IconWidth=16 IconHeight=16 AnchorCss="s4-breadcrumb-anchor" AnchorOpenCss="s4-breadcrumb-anchor-open" MenuCss="s4-breadcrumb-menu"><div class="s4-breadcrumb-top">  
61:                                               <asp:Label runat="server" CssClass="s4-breadcrumb-header" Text="<%$Resources:wss,master_breadcrumbHeader%>" /></div><asp:ContentPlaceHolder id="PlaceHolderTitleBreadcrumb" runat="server"><SharePoint:ListSiteMapPath runat="server" SiteMapProviders="SPSiteMapProvider,SPContentMapProvider" RenderCurrentNodeAsLink="false" PathSeparator="" CssClass="s4-breadcrumb" NodeStyle-CssClass="s4-breadcrumbNode" CurrentNodeStyle-CssClass="s4-breadcrumbCurrentNode" RootNodeStyle-CssClass="s4-breadcrumbRootNode" NodeImageOffsetX=0 NodeImageOffsetY=353 NodeImageWidth=16 NodeImageHeight=16 NodeImageUrl="/_layouts/images/fgimg.png" RTLNodeImageOffsetX=0 RTLNodeImageOffsetY=376 RTLNodeImageWidth=16 RTLNodeImageHeight=16 RTLNodeImageUrl="/_layouts/images/fgimg.png" HideInteriorRootNodes="true" SkipLinkText="" /></asp:ContentPlaceHolder></SharePoint:PopoutMenu><div class="s4-die"><asp:ContentPlaceHolder id="PlaceHolderGlobalNavigationSiteMap" runat="server" Visible="false"/></div></asp:ContentPlaceHolder><SharePoint:PageStateActionButton id="PageStateActionButton" runat="server" Visible="false" /></SharePoint:SPRibbonPeripheralContent><SharePoint:SPRibbonPeripheralContent runat="server" Location="TabRowRight" ID="RibbonTabRowRight" CssClass="s4-trc-container s4-notdlg"><SharePoint:DelegateControl runat="server" ID="GlobalDelegate0" ControlId="GlobalSiteLink0" /><a href="#" tabindex="-1" style="display:none"></a><a href="#" tabindex="-1" style="display:none"></a><div class="s4-trc-container-menu"><div><wssuc:Welcome id="IdWelcome" runat="server" EnableViewState="false"/><wssuc:MUISelector ID="IdMuiSelector" runat="server"/></div></div><SharePoint:DelegateControl ControlId="GlobalSiteLink2" ID="GlobalDelegate2" Scope="Farm" runat="server" /></SharePoint:SPRibbonPeripheralContent></SharePoint:SPRibbon></div><div id="notificationArea" class="s4-noti"></div><asp:ContentPlaceHolder ID="SPNavigation" runat="server">  
62:            <SharePoint:DelegateControl runat="server" ControlId="PublishingConsole" Id="PublishingConsoleDelegate"/></asp:ContentPlaceHolder><div id="WebPartAdderUpdatePanelContainer"><asp:UpdatePanel ID="WebPartAdderUpdatePanel" UpdateMode="Conditional" ChildrenAsTriggers="false" runat="server"><ContentTemplate>  
63:                 <WebPartPages:WebPartAdder ID="WebPartAdder" runat="server"/>  
64:                           </ContentTemplate><Triggers>  
65:                                <asp:PostBackTrigger ControlID="WebPartAdder" />  
66:                           </Triggers>  
67:                      </asp:UpdatePanel></div></div><!-- END RIBBON --><!-- **************************************************************** -->  
68:   <asp:Panel runat="server" ID="workspace">  
69:      <div id="s4-workspace">  
70:        <!-- IGNORE. Sharepoint Div-->  
71:        <div id="s4-bodyContainer">  
72:          <!-- IGNORE. Sharepoint Div-->  
73:          <div id="MSO_ContentDiv" runat="server">  
74:            <!-- IGNORE. Sharepoint Div-->  
75:            <sharepoint:spsecuritytrimmedcontrol runat="server" authenticationrestrictions="AuthenticatedUsersOnly"><div id="s4-statusbarcontainer"><div id="pageStatusBar" class="s4-status-s1"></div></div><SharePoint:VisualUpgradePreviewStatus runat="server" /></sharepoint:spsecuritytrimmedcontrol>  
76:            <!-- NOTE to discuss - any reason we're not using html5 header element?-->  
77:            <!-- Skip links for accessing page sections quickly on AT -->  
78:            <ul class="hide">  
79:              <li><a href="#main-content" title="Skip to right column">Skip main content</a></li>  
80:              <li><a href="#primary-navigation" title="Skip to main navigation">Skip to site navigation</a></li>  
81:              <li><a href="#secondary-navigation" title="Skip to left column">Skip to section navigation</a></li>  
82:              <li><a href="#xxx-shortcuts" title="Skip to campus shortcuts">Skip to XXX shortcuts</a></li>  
83:              <li><a href="#search" title="search">Skip to search</a></li>  
84:            </ul>  
85:            <!-- /skiplinks -->  
86:            <!-- Hidden xxx Shortcuts which appear when "XXX Shortcuts" is clicked. -->  
87:            <div class="xxx-shortcuts-drawer" id="sliding-drawer" style="display: none;">  
88:            </div>  
89:            <!-- /tactical-drawer -->  
90:            <!--Slider for small screen navigation-->  
91:             <nav class="unit size1of5" id="nav-slider" style="display:none;">  
92:                  <span class="unit size3of5">  
93:                     <a name="search"></a>  
94:                     <!--TO DO MAKE THIS SEARCH BOX WORK-->  
95:                                               <input class="unit search-input" id="search_input_slider" name="search_input_slider" type="text" onkeypress="javascript:XXX.SearchBox.KeyPress(event);" /><input name="search_submit" class="unit search-btn" type="button" onclick="javascript:XXX.SearchBox.Search();" />  
96:                                </span>  
97:                                <ul class="tab-titles">  
98:                                     <li class="site-menu-title"><a class="tab-toggle">Site Menu</a></li>  
99:                                     <li class="xxx-shortcuts-title"><a class="tab-toggle">xxx Shortcuts</a></li>  
100:                                </ul>  
101:                                <div class="tab nav-tab">  
102:                                      <xxxNav:CustomNavigation runat="server" NavigationProvider="CurrentNavSiteMapProvider" LevelDepth="3" HighestParentActiveOnly="false" CSSClass="unstyled" NavigationID="slider-nav" IncludeUniqueIdentifiers="FALSE" IncludeRootHeader="FALSE"></xxxNav:CustomNavigation>  
103:                                 </div>  
104:                                 <div class="tab shortcuts-tab">  
105:                                      <xxx:XXXResponsiveShortcuts ID="shortcutsSliderControl" runat="server"></xxx:XXXResponsiveShortcuts>  
106:                                 </div>  
107:                            </nav>  
108:                           <!-- /slider-->  
109:                           <div class="body-content">  
110:            <div class="line masthead">  
111:                 <div class="unitRight size2of5">  
112:                <a name="xxx-shortcuts" class="unit xxx-shortcuts">XXX Shortcuts</a>  
113:                <span class="unit xxx-search">  
114:                     <a name="search"></a>                           
115:                     <asp:ContentPlaceHolder id="PlaceHolderSearchArea" runat="server">  
116:                                               <input class="unit search-input" id="search_input" name="search_input" type="text" onkeypress="javascript:XXX.SearchBox.KeyPress(event);" /><input name="search_submit" class="unit search-btn" type="button" onclick="javascript:XXX.SearchBox.Search();" />  
117:                                          </asp:ContentPlaceHolder>  
118:                                     </span>  
119:                <nav class="off-canvas-navigation">  
120:                                         <a class="menu-button" href="#nav-slider">Pretty icon of horizontal lines</a>  
121:                                   </nav>  
122:              </div>  
123:              <div class="unit size5of5 xxx-logo">  
124:                <a class="unit logo-short" href="#">XXX University</a> <a class="unit h1 site-title"  
125:                  href="#">Responsive (TODO! Dynamic name)</a>  
126:              </div>  
127:            </div>  
128:            <!-- /line /masthead -->  
129:            <nav class="line">  
130:                                     <xxxNav:CustomNavigation runat="server" NavigationProvider="GlobalNavSiteMapProvider" LevelDepth="2" HighestParentActiveOnly="true" CSSClass="unit size1of1 nav-primary" NavigationID="global-nav" IncludeUniqueIdentifiers="TRUE" IncludeRootHeader="FALSE"></xxxNav:CustomNavigation>  
131:                           <div class="quick-links" style="display:none">  
132:                      <xxx:ReusableContent runat="server" ID="navQuickLinks" ReusableContentListItemTitle="Quick Links"/>  
133:                           </div>  
134:                           </nav>  
135:            <!-- /section /line -->  
136:            <div class="line content-body">  
137:              <asp:ContentPlaceHolder ID="PlaceHolderLeftNavBar" runat="server">  
138:                <nav class="unit size1of5" role="navigation" id="nav-secondary">  
139:                                                <xxxNav:CustomNavigation runat="server" NavigationProvider="CurrentNavSiteMapProvider" LevelDepth="3" HighestParentActiveOnly="false" CSSClass="unstyled nav-secondary" NavigationID="left-nav" IncludeUniqueIdentifiers="FALSE" IncludeRootHeader="FALSE"></xxxNav:CustomNavigation>  
140:                                           </nav>  
141:              </asp:ContentPlaceHolder>  
142:              <!-- NOTE to discuss - place article in masterpage or place that in page layouts?-->  
143:              <asp:ContentPlaceHolder ID="PlaceHolderMain" runat="server" />  
144:            </div>  
145:            <!-- /content-body -->  
146:            <div class="line footer-socialicons">  
147:              <div class="unitRight size1of5">  
148:                <a class="unit icon-twitter-sm" href="#" title="Facebook">Facebook</a> <a class="unit icon-vimeo-sm"  
149:                  href="#" title="LinkedIn">LinkedIn</a> <a class="unit icon-youtube-sm" href="#" title="Twitter">  
150:                    Twitter</a> <a class="unit icon-smashup=sm" href="#" title="Social Media Smashup">RSS</a>  
151:              </div>  
152:            </div>  
153:            <!-- /line /footer-socialicons -->  
154:            <!-- TODO make footer reusable content somehow...make easy for CE's?-->  
155:            <div class="line footer">              
156:              <!-- /line -->  
157:              <div class="hiddenShortcuts" style="display:none;">  
158:                   <xxx:XXXResponsiveShortcuts ID="shortcutsControl" runat="server"></xxx:XXXResponsiveShortcuts>  
159:                                </div>  
160:            </div>  
161:            <!-- /line /footer -->  
162:            <div class="line copyright">  
163:            </div>  
164:            <!-- /line /copyright -->  
165:            </div><!-- /slider-->  
166:          </div>  
167:          <!-- IGNORE. /MSO_ContentDiv -->  
168:        </div>  
169:        <!-- IGNORE. End of SP Div, /s4-bodyContainer-->  
170:      </div>  
171:      <!-- IGNORE. End of SP Div, /s4-workspace-->  
172:    </asp:Panel>  
173:  </xxxOpt:RestrictedRenderForm>  
174:       <asp:Panel runat="server" Visible="false">  
175:            <!-- s4-titlerow PlaceHolders -->            
176:            <asp:ContentPlaceHolder id="PlaceHolderPageTitle" runat="server"/>  
177:            <asp:ContentPlaceHolder id="PlaceHolderSiteName" runat="server"/>  
178:            <asp:ContentPlaceHolder id="PlaceHolderPageTitleInTitleArea" runat="server" />  
179:            <asp:ContentPlaceHolder id="PlaceHolderPageDescription" runat="server"/>  
180:            <asp:ContentPlaceHolder id="PlaceHolderHorizontalNav" runat="server"/>  
181:            <!-- s4-leftpanel PlaceHolders -->  
182:            <asp:ContentPlaceHolder id="PlaceHolderLeftNavBarDataSource" runat="server"/>  
183:            <asp:ContentPlaceHolder id="PlaceHolderCalendarNavigator" runat="server" />  
184:            <asp:ContentPlaceHolder id="PlaceHolderLeftActions" runat="server"/>  
185:            <asp:ContentPlaceHolder id="PlaceHolderLeftNavBarTop" runat="server"/>            
186:            <asp:ContentPlaceHolder id="PlaceHolderQuickLaunchTop" runat="server"/>  
187:            <asp:ContentPlaceHolder id="PlaceHolderQuickLaunchBottom" runat="server"/>  
188:            <!-- s4-ca PlaceHolders -->  
189:            <asp:ContentPlaceHolder id="PlaceHolderPageImage" runat="server"/>  
190:            <asp:ContentPlaceHolder id="PlaceHolderTitleLeftBorder" runat="server"/>  
191:            <asp:ContentPlaceHolder id="PlaceHolderMiniConsole" runat="server"/>  
192:            <asp:ContentPlaceHolder id="PlaceHolderTitleRightMargin" runat="server"/>  
193:            <asp:ContentPlaceHolder id="PlaceHolderTitleAreaSeparator" runat="server"/>  
194:            <asp:ContentPlaceHolder id="PlaceHolderLeftNavBarBorder" runat="server"/>  
195:            <asp:ContentPlaceHolder id="PlaceHolderBodyLeftBorder" runat="server"/>  
196:            <asp:ContentPlaceHolder id="PlaceHolderBodyRightMargin" runat="server"/>  
197:            <!-- body PlaceHolders -->  
198:            <asp:ContentPlaceHolder id="PlaceHolderUtilityContent" runat="server"/>       
199:       </asp:Panel>  
200:       <footer>  
201:       <script type="text/javascript">  
202:            $('body').removeClass('no-js').addClass('js');  
203:       </script>  
204:       <xxxOpt:QuickConcat runat="server" JSFiles="local/jquery-1.7.2.min.js;local/jquery.touchSwipe.min.js;local/jquery.pageslide.js;local/XXX-responsive.js;local/XXX-standard.master.js" CSSFiles="local/responsive.css" AlwaysRecreateFile="true"></xxxOpt:QuickConcat>  
205:       <asp:ContentPlaceHolder id="PlaceHolderNavSpacer" runat="server">  
206:       </asp:ContentPlaceHolder>  
207:       </footer>  
208:  </body>  
209:  </html>  

1 comment:

  1. This was the beginning of brilliant. A couple of things to not on your RestrictedRenderForm it appears that you are rendering only the workspace in anonymous mode, however some of the controls in the webpart manager area even in anonymous mode are required to allow webparts to insert javascript onto the page, as well as to render things like the hidden webpart zone for use on anonymous pages that have webparts embeded in richhtml areas.

    ReplyDelete