You can specify the attributes that will be submitted to the form helper. Specify the attribute "autofill" and set its value to "off".
... echo $this->Form->input('username', array( 'label' => 'Please enter your username', 'class' => 'pure-u-1-2', 'autocomplete' => 'off' )); echo $this->Form->input('password', array( 'label' => 'Please enter your password', 'class' => 'pure-u-1-2', 'autocomplete' => 'off' )); ...
Which leads to something like this for your HTML:
<input name="data[Model][username]" autocomplete="off" class="pure-u-1-2" id="ModelUsername" type="text">
You can also do this on all forms, not just at every entrance. Just specify the same attribute and value in the form, create this:
... echo $this->Form->create('Model', array( 'class' => 'class', 'autocomplete' => 'off' ));
This will give you something like this in your HTML:
<form action=".../Model/Action" class="class" autocomplete="off" id="ModelActionForm" method="post" accept-charset="utf-8">
NOTE Multiple browsers will now ignore autocomplete = "off" or autocomplete = "false". The workaround is to put the hidden text and password field in front of all the other inputs in your form. The browsers will be filled with the ones you want to leave alone.
karns source share