Saturday, January 28, 2012

Sharpoint Mobile : Hide links

MobileDefaultTemplates.ascx   & GwbMobileDefaultTemplates.ascx are the default rendering templates for mobile pages in Sharepoint 2010.

These templates are present in control templates folders in 14 hive.

For hiding links in mobile view, we need to create a custom rendering template and deploy to the control templates 

Here is the sample template, I'm overrriding the out of the box templates here. the below templates are empty, thus in order to hide the links I'm having empty templates.

You can find the id's of the existing templates from MobileDefaultTemplates.ascx   & GwbMobileDefaultTemplates.ascx


<SharePoint:RenderingTemplate RunAt="Server" id="MobilePageNavigationWithCss" >
       <Template>
       </Template>
</SharePoint:RenderingTemplate>
<SharePoint:RenderingTemplate RunAt="Server" id="WebPartMobileSummaryViewContents">
       <Template>
       </Template>
</SharePoint:RenderingTemplate>
<SharePoint:RenderingTemplate RunAt="Server" id="WebPartMobileSummaryViewTitle">
       <Template>
       </Template>
</SharePoint:RenderingTemplate>
<SharePoint:RenderingTemplate RunAt="Server" id="WebPartMobileSummaryViewNavigation">
       <Template>
       </Template>
</SharePoint:RenderingTemplate>

No comments:

Post a Comment