Learn how to a build a cloud-first strategyRegister Now

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 353
  • Last Modified:

'Pub' is undefined error

I have created a custom masterpage, and page layout. When attempted to edit the custom layout page, i am getting the following error:

pub error
I have verified the pub delegate control is placed within the master page.

                <asp:ContentPlaceHolder ID="SPNavigation" runat="server">
                    <SharePoint:DelegateControl runat="server" ControlId="PublishingConsole" ID="PublishingConsoleDelegate">

Open in new window

  • 2
2 Solutions
You need to include a reference to: "SP.UI.Pub.Ribbon.js" in your page somewhere (see if its loaded using developer tools in IE/Chrome  ).

However, as this should come automatically in your masterpage, I would guess its because a feature is not enabled, so check that the feature: "SharePoint Server Publishing" is enabled for the site.
brendanlefavreAuthor Commented:
The masterpage needed to be updated, and the problem was resolved.
brendanlefavreAuthor Commented:
issue resolved

Featured Post

Free Backup Tool for VMware and Hyper-V

Restore full virtual machine or individual guest files from 19 common file systems directly from the backup file. Schedule VM backups with PowerShell scripts. Set desired time, lean back and let the script to notify you via email upon completion.  

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now