Friday, August 31, 2012

Hide first link from global navigation

.s4-tn li.static > a{
display: none !important;
.s4-tn li.static > ul a{
display: block !important;

Wednesday, August 8, 2012

Hide column on SharePoint list forms - JavaScript

Hide column on Sharepoint Dispform.aspx, Editform.aspx, Newform.aspx using a JavaScript.
Copy the script on desired form under the
<asp:Content ContentPlaceHolderId="PlaceHolderAdditionalPageHead" runat="server"> tag:

<script language="javascript" type="text/javascript">
function findacontrol(FieldName) {
   var arr = document.getElementsByTagName("!");
   // get all comments
   for (var i=0;i < arr.length; i++ )
      // now match the field name
      if (arr[i].innerHTML.indexOf(FieldName) > 0)
      {         return arr[i];      }

function hideFields() {
var control = findacontrol("Column-1");"none";

control = findacontrol(" Column-2");"none";

Tuesday, August 7, 2012

Error 401.1 when browsed a web that uses Integrated Authentication and is hosted on IIS

1.       Click Start, click Run, type regedit, and then click OK.
2.       In Registry Editor, locate and then click the following registry key:
3.       Right-click MSV1_0, point to New, and then click Multi-String Value.
4.       Type BackConnectionHostNames, and then press ENTER.
5.       Right-click BackConnectionHostNames, and then click Modify.
6.       In the Value data box, type the host name or the host names for the sites that are on the local computer, and then click OK.
7.       Quit Registry Editor, and then restart the IISAdmin service.

How to launch a document by clicking a link to the file?

Word: <a href='ms-word:ofe|u|path/to/web/word/document.docx'>Link to document</a> Excel: <a href='ms-excel:o...