Tag Info

Hot answers tagged

3

For On-Prem installations: You can always change the master page from PowerShell using the below script: Connect-SPOService -Url "tenant admin url" -Credentials "username" $web = Get-SPOSite http://sharepoint $web.CustomMasterUrl = "/_catalogs/masterpage/nightandday.master" $web.MasterUrl = "/_catalogs/masterpage/nightandday.master" $web.Update() Source: ...


3

Create an Event Receiver. In Visual Studio, right click project => Add new item => Event Receiver => Web Events, Handle the following events: A Site is being provisioned. The following override will be generated and fire on every new site creation. Just insert the code within: public override void WebProvisioned(SPWebEventProperties properties) { ...


2

Your user control needs to target a delegate control placed in the page body not AdditionalPageHead. AdditionalPageHead targets the html head element and is used for adding additional things to the head, like css and javascript files. A delegate control in the body is the appropriate place for an asp:button to live. So within the masterpage, you would ...


1

In my experience you can always get back to the Site Settings page even if you break your Master Page ({your site url}/_layouts/settings.aspx). Then if you have a publishing site, you should be able to click on the Master Page link under Look and Feel and then switch the master page to a different one that you haven't edited. If you have a team site, this ...


1

After a while I discovered that just editing (adding a space) to the master page in SharePoint Designer fixed it. I then copied the resulting saved SharePoint Designer master page back into my solution and deployed that and it worked fine. Comparing the two files, the master page that had been provided to me originally had some extra attributes in the ...


1

In new versions of SharePoint the new masterpages often contains elements of the masterpages from the previous version of SharePoint to support upgraded sites so no functionality is lost. This element is the legacy statusbar from SharePoint 2010. DeltaPageStatusBar is the one used in SharePoint 2013, making the legacy statusbar redundant. It causes no harm ...


1

this container is for displaying status informations. And you are right with your research that also information about the page status (e.g. checked out or checked in) will displayed. This is a system element of the Masterpage structure and I think required. In cause of this, it is not good or recommended to remove or rename the element. SharePoint 2013 ...


1

You haven't added your control. You've just registered it. After the registration you need to add another line like so: <!--SPM:<LogOut:LogOutUserControl id="LlgOutUserControl" runat="server" />-->


1

The probably simplest method would be to add the following CSS to your masterpage, assuming your custom searchbox has an HTML element ID of #Searchbox: <style> #aspnetForm[action*="settings.aspx"] #SearchBox, #aspnetForm[action*="addanapp.aspx"] #SearchBox { display: none; } </style>


1

The relationship between .html and .master is a bridge. It has been implemented so that developers who are not familiar with ASP.NET masterpages and SharePoint can use the .html file to do the changes in a "environment" they are more or less familiar with. I'm going to assume this is an on-premise solution, so yes, downloading and putting the .js file in ...


1

I found out that I need to use another control to achieve the results I wanted. With this snippet inside the page layout (eg inside the PlaceHolderPageTitleInTitleArea placehoder) it renders me the path nicely to the current page/element: <h1 id="pageTitle" class="ms-core-pageTitle"> <!--SPM:<asp:ContentPlaceHolder id="PlaceHolderSiteName" ...


1

Aside from any API calls, why not just modify the master pages to include some javascript that sets a variable telling which master it is Var master="masters?asps"



Only top voted, non community-wiki answers of a minimum length are eligible