Is there any reason when I create a Web Part Page in publishing site the left navigation is missing? If yes, What is the proper way to create a page that will include the left quick nav?
3 Answers
If you don't want to use javascript/jQuery, here's another way to get the left navigation back in web part pages.
- Create a new web part page
- Edit the page in SharePoint Designer
- Remove custom css
Delete this code block:
<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>
<SharePoint:UIVersionedContent ID="WebPartPageHideQLStyles" UIVersion="4" runat="server">
4.-Remove the overrides for the left column
Remove all three lines:
<asp:Content ContentPlaceHolderId="PlaceHolderPageImage" runat="server"></asp:Content>
<asp:Content ContentPlaceHolderId="PlaceHolderNavSpacer" runat="server"></asp:Content>
<asp:Content ContentPlaceHolderId="PlaceHolderLeftNavBar" runat="server"></asp:Content>
Source: http://techmikael.blogspot.it/2011/08/adding-left-navigation-menu-to-web-part.html
If I use following method then I get both web part page and the left navigation.
Go to site actions-->More options-->Publishing Page. I selected "(Welcome Page) Blank Web Part page"
-
Well, this is a different thing. You asked for a web part page, now you're using a Publishing Page. Jan 14, 2014 at 8:15
In SharePoint 2010, the left nav is inexplicably hidden in web part pages. You can’t just change the page layout for these pages as you can with page layout based pages that are stored in the /pages/ library (via the publishing feature).
<!– Turn on left navigation –>
<script type=”text/javascript”>
$(document).ready(function() {
$(“#s4-leftpanel”).show();
$(“.s4-ca”).css(‘margin-left’, ’155px’);
});
</script>
-
-
1Because it is a webpart page and not a Publishing Page based on a page layout Jan 13, 2014 at 16:35
-
This doesn't seem to work in WSS: <!– Turn on left navigation –> <script type=”text/javascript”> $(document).ready(function() { $(“#s4-leftpanel”).show(); $(“.s4-ca”).css(‘margin-left’, ’155px’); }); </script>– CarlMay 28, 2015 at 15:16