Control autocompleet on a field or form

For some pages or forms I want to stop the browser from autocompleting the input. This should be possible by adding the Autocomplete attribute. Do I need to make my own widget to add this to a field, or is there an easier way to add an attribute to a standaard Mendix widget?
2 answers
  • Well I think currently it's only possible by using the custom javascript widget and some javascript to add the attribute to the fields you define.
  • Or indeed make a custom widget to enable this.

I would go for the first approach because it's faster and can apply on all the elements you want.


The easiest solution to modify DOM would be the UX manipulator widget. I think that should suffice for what you want to do.

If you'd like on the other hand to run your own code you can also use an HTML snippet widget. Just be careful if you choose to use the snippet, as javascript onLoad events can be temperamental with Mendix.