XPages Tip – Disable Autocomplete on All Fields via the Theme

In my last post, I showed how to disable autocomplete on a single field. In this post, I’ll show how to disable it application-wide via the theme.

If you want to prevent autocomplete on all fields in your application, you can do it in one fell swoop by adding this code to your theme:

<!-- Set all edit box controls to disable autocomplete -->
<control>
  <name>InputField.EditBox</name>
  <property mode="override">
    <name>autocomplete</name>
    <value>off</value>
  </property>
</control>

This will automatically insert the autocomplete="off" attribute into all Edit Box controls in the application.

Here’s an example of what a field now looks like in the browser page source:

<input type="text" id="view:_id1:AutoComplete" name="view:_id1:AutoComplete" autocomplete="off" class="xspInputFieldEditBox"><br>

2 responses to “XPages Tip – Disable Autocomplete on All Fields via the Theme”

  1. Sven Hasselbach says :

    Don’t forget Textareas. And the *AutoCapitalize* Feature: http://hasselba.ch/blog/?p=1037

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: