Password
Supported products
- Central CMS
- Central Forms
- Central Connect
Generates a password input field.
Basic usage
- Twig
- HTML
{{
form.password({
'label': 'My label',
'id': 'password-1',
'name': 'password-1'
})
}}
<div class="form__group">
<label for="password-1" class="control__label">My label</label>
<div class="controls">
<input id="password-1" name="password-1" type="password" class="form__control" />
</div>
</div>
Helper options
You can configure this helper using the common helper options. The following options are specific to this helper.
Option | Type | Description |
---|---|---|
append | string | Text or markup to include after the input element |
append_type | string | Use only when appending a button. button is the only valid value |
prepend | string | Text or markup to include before the input element |
prepend_type | string | Use only when prepending a button. button is the only valid value |
readonly | bool | Adds readonly attribute and uses a dashed outline to indicate lack of interaction |