Tag Info

Hot answers tagged

32

I have resolved the same issue using the my post. In Feature.xml add a reference to the Feature receiver class. <?xml version="1.0" encoding="utf-8"?> <Feature xmlns="http://schemas.microsoft.com/sharepoint/" Id="{35867BDA-82DC-418c-9005-79CCC363E3CD}" Title="blah" Description="blah" Scope="Site" ...


20

Did you remember to check in the master page? Site Actions > Site Settings > Galleries > Master pages and page layouts Find your master page, select it and select Publish then Approve


12

If you want to do it at page level, you can assign a different master page on "OnPreInit" event. Below is the example to do it on layout page if you have publishing site : public class MyPublishingLayoutPage:PublishingLayoutPage { protected override void OnPreInit(EventArgs e) { base.OnPreInit(e); if ...


10

It's in the 14 hive at: C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\LAYOUTS


9

The short story: Usually you'll set the master page as both default and custom master page, the most common exception being a very customized master page for publishing which can't be used for ordinary pages in which case you'll only set it as custom master page. The full story: When creating pages in SharePoint your main options for setting the ...


9

The log file should get you the path that SharePoint unsuccessfully tries to resolve. Try adding "~sitecollection" first in the ScriptLink like: <SharePoint:ScriptLink language="javascript" name="~sitecollection/custom/jquery-1.10.2.min.js" runat="server" Localizable="false" /> but this will only work inside the "the_new_osce_portal" Site ...


8

You have a couple options here (...I've used both successfully in the past): 1) Call _spBodyOnLoadFunctionNames.push("function()"); replacing function with the name of the function in your webpart. This will cause your function to be executed after the body of the page if fully loaded and in sequence with other startup client-side scripts. 2) You can go ...


8

You can turn on the Publishing feature for the Root site and in the Site Action -> Site Settings -> Master Pages you will see a screen like below: Here you can specify to inherit the root-site master page for sub-sites! Also, if its just a CSS that you have used - at the bottom you can see an option to Specify a CSS to be used by this publishing site and ...


7

My question is why on earth you'd want to remove core.js. It contains JavaScript functions which are useful even in a public-facing situation, and that's why you are getting errors. These include dropdown menu items, page layout manipulation, expand/collapse behavior on list views, etc. Remember that core.js will only be downloaded once per user when they ...


7

As long as you dont customize (unghost) your page layout, updating through declarative feature should work fine. By any chance did you create your page layout in SharePoint designer? If you did, a little known "feature" is that even though you provision your page layouts with GhostableInLibrary they will be unghosted and hence you will only be able to take ...


7

There are many ways that you can approach this issue and it all comes down to what the desired functionality and behavior is for both the user and the content editor. One of the most common ways I have done this in the past is to use one master page that has all the publishing controls still in it. By default you have to be logged into a site for it to ...


7

Since respond.js is a presentational script, its placement within your HTML can dramatically impact page performance and execution time, especially on less capable browsers with slower JS engines. This module takes the guesswork out of placement and puts the script where it will be most effective. Optimal location is in the head after your CSS but before ...


7

You can copy any of the existing MasterPage's html file (I hope you have already figured that out) and go to Site Settings -> Design Manager -> Edit Master Page Now click your copied MasterPage and at the top-right you can see Snippets.. This is newly introduced in SharePoint 2013 and further explained here Now if you click Search Box, this will give you ...


7

Hardcoding is never a nice solution! Look in to the SuiteBarBrandingDelegate control: Elements.xml: <?xml version="1.0" encoding="utf-8"?> <Elements xmlns="http://schemas.microsoft.com/sharepoint/"> <!-- SuiteBarBrandingDelegate (the top-left "SharePoint" text on a page) --> <Control ...


7

Use the MasterUrl and CustomMasterUrl properties of Web: using (var ctx = new ClientContext( url )) { var web = ctx.Web; var masterPageUrl = String.Format( "{0}/_catalogs/masterpage/oslo.master", ctx.Web.ServerRelativeUrl ); web.MasterUrl = masterPageUrl; web.CustomMasterUrl = masterPageUrl; web.Update(); ctx.Load( web ); ...


6

D'oh! turns out setting the debug="false" value in the system.web section removes the .debug.js files from the client download... <compilation batch="false" debug="false" optimizeCompilations="true">


6

First of all, never, ever modify v4.master. That is a Microsoft page and will likely be replaced/updated in a future service pack and then poof, there goes your master page :) Create a copy of it and use that instead. If you put the web parts in the standard web part zones in the master page, all new pages that do not have content defined for those zones ...


6

In the most concise terms I can think of - a Page Layout is used to display content, a Master Page governs the look and feel for the whole site. A Page Layout has an associated content type, therefore it stores content, and a page derived from a Page Layout will store the content in the content type's fields. A MasterPage does not have a content type and ...


6

If your goal is to have a different look and feel for different users, you can use a single Master Page, and include steps that only target specific profiles (anonymous users in your case). Search the internet for the following terms: SPSecurityTrimmedControl and AnonymousTemplate. It is what I use on this draft page: http://usermanagedsolutions.com For ...


6

You can try using <SharePoint:CssRegistration name="<% $SPUrl:~sitecollection/Style Library/My.css %>" After="corev4.css" runat="server"/> to resolve a full path in the masterpage, though I have a funny feeling that might only work in Publishing Pages...


6

This is a common problem when using multiple JavaScript libraries as many of them define $() SharePoint is using ASP.NET Ajax so if you include JQuery you should do that in noConflict mode. You turn that on using jQuery.noConflict(); Now $ will never mean jQuery unless you use constructs like: jQuery(document).ready(function($){ /* code using $ */ ...


6

I would not advice to edit the Seatle.master. Instead I'd advice you to just take a copy of it and rename + edit the copy. In that way, in case anything goes wrong, you still have a solid fallback masterpage. Why some may advice to edit the html version, that is to support the Design Manager - But that method is primarily opinion-based. Regarding your ...


6

In Init.Js there is a function called AllowCSSFiltersOnIE8(). It checks for IE version and if it is Ie8 or below. Adds ms-core-needIEFilter css class to body tag, then checks for border style on ms-hcTest, and if it is not applied, removes css filter for s4-workspace. So this element is just for checking whether there is a need to use filters or not. And ...


6

Inside the current site's Site Settings, navigate to Site Collection Administration > Site Collection Features. Activate SharePoint Server Publishing Infastructure if it's available... if it's not, you may be using SharePoint Foundation. Navigate to Site Actions > Manage Site Features, and activate the same feature (which should now be visible. Return to ...


6

MasterPage is allowed deployed at site collection scope. If you want to set your masterpage as default masterpage below are the common methods: Write code in a feature receiver. Through Powershell commands Through UI (SharePoint Publishing Infrastructure and SharePoint Publishing feature needs to be activated to do this.) Through SharePoint designer. Now ...


6

On the site collection level, the SharePoint Publishing Infrastructure Feature needs to be active, and on the web level, SharePoint Server Publishing needs to be active. If not, you are not allowed to change master page.


5

You can add a search web part to the page and change the scope to search for people instead.


5

You can navigate to the master page gallery via the root site Site Actions>Site Settings>(Galleries)Master pages and page layouts. Then select the master page file you want and click Download a Copy from the ribbon. The url for the master page gallery is: http://server/_catalogs/masterpage


5

If you want to copy your master page to another site collection you can download your master page from the master page gallery and upload it to the the master page gallery of the second site collection. From the root site Site Actions > Site Settings > (Galleries)Master pages and page layouts If you want to deploy the same master page to multiple site ...


5

This post describes how can you change masterpage dynamiccally.



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