Home » Sharepoint 2010RSS

Web Part Page doesn't show current navigation

Hi!

I'm having a problem with the navigation of web part page in Sharepoint 2010.

For starters I need to say that I am a web designer and learning to brand Sharepoint 2010 wich means I'm not that tech-savvy so bear with me.

We have created an intranet publishing site with Sharepoint 2010 and I have designed a custom master page with styles through Visual Studio 2010. The intranet site looks fine with the new design and I got navigation working with fly out menus, semantic subpages etc.

The problem is: when I create a normal page the current sub-navigation is shown and it even shows my created web part page and all is fine, but once I go to this web part page, the left/sub-navigation disappears and I have no idea how to bring it back.

The web part page uses the same master file as every other page.

Everything with the the layout stays the same as my masterpage, except for the menu wich disappear so I thought it might be some property missing on the sub-navigation.

Or do I need to edit something in the web part page layout in the gallery?: Master Page Gallery > BlankWebPartPage.aspx
If so can I do it from Visual Studio?


Here is the code for the left navigation menu:

	    <!-- styles needed to have left nav to the left of the main area -->
	    <div id="s4-leftpanel" class="s4-notdlg">
		    <!-- The quick launch bar / left navigation -->
        <div class="sub-nav">
		      <asp:ContentPlaceHolder id="PlaceHolderLeftNavBar" runat="server">
			      <PublishingNavigation:PortalSiteMapDataSource
				      ID="SiteMapDS"
				      runat="server"
				      EnableViewState="false"
				      SiteMapProvider="CurrentNavigation"
				      StartFromCurrentNode="true"
				      StartingNodeOffset="1"
				      ShowStartingNode="false"
				      TrimNonCurrentTypes="Heading"/>			
			      <SharePoint:AspMenu
				      ID="CurrentNav"
				      runat="server"
				      EnableViewState="false"
				      DataSourceID="SiteMapDS"
				      UseSeparateCSS="false"
				      UseSimpleRendering="true"
				      Orientation="Vertical"
				      StaticDisplayLevels="2"
				      MaximumDynamicDisplayLevels="0"
				      CssClass="" 
				      SkipLinkText="<%$Resources:cms,masterpages_skiplinktext%>"/>			
		      </asp:ContentPlaceHolder>
        </div>
		
		    <!-- The small menu attached Quick Launch bar. Used only on very specific pages -->
		    <asp:ContentPlaceHolder id="PlaceHolderLeftActions" runat ="server"/>
	    </div>

 

Need help urgent!
Thanks!

 

 

4 Answers Found

 

Answer 1

It works editing the webpart page  hiding:

 <asp:Content ContentPlaceHolderId="PlaceHolderLeftNavBar" runat="server"></asp:Content>
<SharePoint:UIVersionedContent ID="WebPartPageHideQLStyles" UIVersion="4" runat="server">
 <ContentTemplate>
<style type="text/css">
body #s4-leftpanel {
 display:none;
}
.s4-ca {
 margin-left:0px;
}
</style>
 </ContentTemplate>
 </SharePoint:UIVersionedContent>

However I'd like to know what I need to edit in the WebPart page template (BlankWebPartPage) So I don't need to do this every time i create a new webpart page.


 

Answer 2

I got the advice that modifying existing page  layout templates can be bad for future compability so I should make a new custom page layout.

If so is there a tutorial somewhere that tells how to make those?

 

Answer 3

Hi,

 

You can create a custom page  layout via UI and then customize it via SharePoint Designer. Creating a page layout using Visual Studio is also available.

 

Here are some step by step tutorials that are worth looking at:

http://blog.beckybertram.com/Lists/Posts/Post.aspx?ID=71

http://blog.henryong.com/2010/06/08/how-to-create-custom-sharepoint-2010-page-layouts-using-sharepoint-designer-2010/

 

Thanks & Regards.

 

Answer 4

Hi,

Thanks for your reply.

I created a custom web  part page  and the left menu is showing up as intended.

However I have problem with the page title that usually shows up on all other pages doesn't show.
It have this id: "PlaceHolderPageTitleInTitleArea" .

I don't want a webpartpage title because it has wrong formatting (alot of tables) and it doesn't recognize the name of the page I created.

I think what I'm looking for having a solution here but it doesn't work for me in SP2010:
http://social.msdn.microsoft.com/Forums/en/sharepointcustomization/thread/b703c4d4-88e1-4cd8-94ed-2e0e8ae8df22

I get the following error message:
Parser error: Unknown server tag "SharePointWebControls:TextField.

Any idea what I should do?

 

 
 
 

<< Previous      Next >>


Microsoft   |   Windows   |   Visual Studio   |   Follow us on Twitter