Tag Info

Hot answers tagged

5

I would advise against this...I would also advise against having an exact copy of the coreV4.css file. Having both these files is going to beef up the load times and increase the needless amount of code the browsers need to go through. Change your CSS registration to the following line. I also always add it after the CoreV4.css not that it makes a ...


4

As Sig suggested there are some changes to the way IE9 handles javascript from previous versions. I found my answer in /_layouts/1031/init.js in the function ProcessImnMarkers() (Ironically, a function you want to overwrite as empty if you actually WANT to hide the IM Presence stuff). Here is the original code of the function: function ProcessImnMarkers() ...


4

Adding to iambriansreed's solution, you can put the comments in Literal controls around the SPSecurityTrimmedControls to prevent SPD from adding the extra rubbish. For example: <asp:Literal runat="server" text="&lt;!-- "/><SharePoint:SPSecurityTrimmedControl PermissionsString="EditListItems" runat="server"><asp:Literal runat="server" ...


4

The line <Property Name="QueryPromptString">$Resources:MyResourceFile,ResourceKey</Property> wokrs fine for me. I think that you should check your resources file. This file should contain ResourceKey which you tries to use in this property. If you use correct resource file and key, the search control displays text depends on the site language. ...


4

Since your master page is now unghosted (= customized = not anymore retrieved from the file system), you'll have a newer version. You can roll back to a previous edition (v1.0 as provisionned by MS) to put you back in a working state. Go to {Your-Site-Collection-Url}/_catalogs/masterpage/Forms/AllItems.aspx, select the v4.master, history and roll back to a ...


3

There is a out of the box content placeholder containing the site name that can be placed inside your masterpage. I believe Randy has it included in the block of content placeholders at the bottom of the page, and you can just bring it up to where you want it. <asp:ContentPlaceHolder id="PlaceHolderSiteName" runat="server"/>


3

The trickiest part of this is making sure the brand gets used for all new mysites created from this point on. To do so you need to make sure your branding conforms to a key prerequisite. Is your brand packaged up in a visual studio .wsp and can it be applied to a given site collection by activating one or more features? If so then you can apply it to all ...


3

I would highly recommend you to start with the Starter Master Pages project by Randy Drisgill over at codeplex - http://startermasterpages.codeplex.com/. In my openion its the best starting point to create a custom master page in SharePoint 2010...


3

The easiest and cleanest way to do this is wrap the control with html comments: <!-- <Sharepoint:SPSecurityTrimmedControl runat="server" Permissions="CreateSSCSite"> --> <SharePoint:CssLink runat="server" Version="4"/> <!-- </Sharepoint:SPSecurityTrimmedControl> --> If the user meets the permissions then it returns: ...


3

A simple PowerShell script would do it. There's a MasterUrl and CustomMasterUrl property on the SPWeb object, so you could just do something simple like Get-SPSite | Get-SPWeb | % {"Site: " + $_.Url + " Master: "+ $_.MasterUrl} to list out the master for every web.


3

Customizing Meeting Workspaces is not as straight forward as one could expect unfortunately (both SP2007 and SP2010). First of all you cannot use Web Templates or Custom Site Definitions because Outlook often will be the one creating the sites using web services, and it is only aware of the OOB site definitions. As i stated in comments elsewhere, feature ...


3

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 ...


3

Since you cannot access the site's normal, web-based UI: Use SharePoint Designer 2010 and in the Site Objects navigation menu on the left, select Master Pages. Right click your v4.master and either reset to a specific version or edit it to make the required changes. Something is going to have to give. There is no magic spell that can fix the issue. You will ...


3

To use Client OM, you need a reference to SP.js For production: <SharePoint:ScriptLink Name="sp.js" runat="server" OnDemand="true" Localizable="false" /> For development purpose: <SharePoint:ScriptLink Name="sp.debug.js" runat="server" OnDemand="true" Localizable="false" /> Moreover, there is also another way to declare it using the ...


3

Medes, Don't remove the PlaceHolders from MasterPage, bad bad practice! As they are used by SharePoint internally to place content accordingly on the pages... Below URL gives the list of Default Content Place Holders and information that is kept into them [It is for SharePoint 2010, but I hope not much changes are there]: Working with content placeholder ...


3

To do this properly, leave corev4.css alone and define your own custom CSS file that includes only the CSS classes that you want to override. CSS loads in order so as long as your custom CSS is loaded after corev4, your styles will be applied. Since your new file includes only the CSS classes that were modified, it will also be much easier to manage than ...


3

Why not just check the CustomMasterUrl and MasterUrl properties that are on the SPWeb object itself and bypass the slow and expensive GetFile() altogether? if ($Web.MasterUrl.EndsWith("corp.master") -eq $false) $Web.MasterUrl + " : " + $Web.Url }


3

Starter Master Pages is a great resource for learning about SharePoint 2010 master pages and a good starting point for SharePoint 2010 branding projects From _starter_publishing.master <!-- s4-ca is the main body div --> <div class="s4-ca"> <div class="s4-notdlg"> <!-- links for I like it and Tags and Notes ...


2

There isn't a way to prevent the ContentPlaceHolder from being 'overriden'. If you have control over the html of the masterpage, you could can: Move the defaults contents outside the content placeholder (if you are sure that the content should always be present on the page). Then put a <div style="display:none">..</div> around the placeholder. ...


2

First, the SharePoint compatibility list says it should work perfectly with IE9, thats correct. BUT only if you use X-UA-COMPATIBLE with "IE=8;". This is AFAIK the only supported scenario by Microsoft. Since I'm not working for Microsoft you can get an official statement by opening a support request (and post back their reply here). So back to your ...


2

Including the navigation in this way effectively bypasses the SharePoint mechanisms for highlighting the current tab so you will have to roll your own. One approach would be to use jQuery to iterate through the urls in the nav (perhaps ".top_nav li a") and compare the url in the each link to the current window.location.href to find the best match. Once ...


2

Insert <SharePoint:ProjectProperty Property="Title" runat="server"/> into the masterpage where you want it. Or if you want it like the default v4.master with a being in the PlaceHolderSiteName ContentPlaceHolder as a link, then use <asp:ContentPlaceHolder id="PlaceHolderSiteName" runat="server"> <SharePoint:SPLinkButton runat="server" ...


2

I think you DON'T need to deploy a whole new solution to replace master page. Make sure the updated master page is deployed on SharePoint root You also need to make sure that master page is not customized. I have observed that, even if you did not customize the master page explicitly, if you copied from SharePoint Designer, it may include following lines in ...


2

Create a custom master page and specify the style ( center alignment) to the div tag that is holding your TopNavContainer. I have used table structure and when I assign align="center" for <tr> tag that was holding <Sharepoint:AspMenu.../> tag.


2

Why don't you Store your js files in Style Library of Site Collection's root web. In such way it can be easily accessed and versioned in case of updates. See below <SharePoint:ScriptLink ID="ScriptLink1" Name="<% $SPUrl:~SiteCollection/Style Library/Core Styles/jquery.js%>" runat="server" />" If you can deploy to _layouts (i.e. not restricted ...


2

Hi custom master page is site master page used for publishing pages only and default master page is system master page, to know more please leaf through this article http://rehmangul.wordpress.com/2009/12/15/master-pages-in-sharepoint/


2

Unless you want to hard code the links or use some custom data source I only know two different ways to do this, the bad and the horrible way. The horrible way Set the current SPWeb to the desired SPWeb and then initialize the menu, for example in a UserControl: using (var site = new SPSite("http://localhost")) { using (var web = site.OpenWeb()) { ...


2

This elements file works for newcustom.master, it needs to be a web feature and then published from the master page catalogue. You will need publishing infrastructure at the minimum to activate it also. <?xml version="1.0" encoding="utf-8"?> <Elements xmlns="http://schemas.microsoft.com/sharepoint/"> <Module Name="MasterPage" ...


2

Yup, If you are familiar with Powershell you can use this script to force subsites to use custom master page, $site = Get-SPSite http://fba.contosotest.com/dv1 $site | Get-SPWeb -limit all | ForEach-Object { $_.MasterUrl = "/dv1/_catalogs/masterpage/custom_v4.master";$_.Update() } $site.Dispose() Otherwise you can use publishing feature, as stated in ...


2

Tom Wilson has a great blog post about how to accomplish this: http://styledpoint.com/blog/fixed-width-centered-aligned-sharepoint-2010-site-updated/ He gives a bunch of examples of how to make this work, but the basic example is: #s4-bodyContainer { width: 950px !important; margin-left:auto; margin-right:auto; }



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