How to Disable Autocomplete for an Entire Sharepoint Farm

Microsoft provides the following sample code to be used in conjunction with a custom.js to disable Autocomplete in Sharepoint:

Create feature files that will inject content into the master page "AdditionalPageHead" section.


Create a new feature folder under SharePoint.

Create the Feature.xml and CustomSchema.xml files like below:


TEMPLATE\FEATURES\DelegateControl\feature.xml

===================

<?xml version="1.0" encoding="utf-8"?>

<Feature Id="<GUID>"

Title = "AUTOCOMPLETE Disable"

Description = "AUTOCOMPLETE Disable"

Creator = "creatorName"

Version = "1.0.0.0"

DefaultResourceFile=" "

Hidden ="TRUE"

Scope="WebApplication"

xmlns="http://schemas.microsoft.com/sharepoint/">

  <ElementManifests>

    <ElementManifest Location="CustomSchema.xml" />

  </ElementManifests>

</Feature>



CustomSchema.xml

=====================

<Elements xmlns="http://schemas.microsoft.com/sharepoint/">

  <Control Id="AdditionalPageHead"

  Sequence="80"

  ControlSrc="~/_controltemplates/custom/custom.ascx">

  </Control>

</Elements>


2. Create a custom.ascx file and place it in the TEMPLATE\CONTROLTEMPLATES\custom\ directory of the 12 hive


Custom.ascx

====================

<%@ Control Language="C#" %>

<script type="text/javascript"

src="/_layouts/Custom/Custom.js" defer="true"></script>


3. Create your custom.js and place it in the Layouts/Custom/ directory of the 12 hive


Custom.js

====================

if (document.getElementsByTagName) {

  var forms = document.getElementsByTagName("form");

  for (var i=0; i<forms.length; i++) {

    forms[i].autocomplete = "off";

  }

}


----------------
Source: http://support.microsoft.com/kb/970782