HTML Attributes

You can define common HTML attributes like id, class or style to any BBCode.

Example:
[text id="my-id" class="my-class-1 my-class-2" style="color: red;"]

AttributeExamplesDescription
idid="my-id"Defines the element id.
Optional.
classclass="my-class"
class="my-class-1 my-class-2"
Defines the element CSS classes.
Optional.
stylestyle="color: red;"
style="color: red; background: blue;"
Defines the element inline CSS style.
Optional.

IMPORTANT: Javascript code is not allowed in attributes for security reasons.

If you want to add a Javascript functionality to a BBCode, the best would be to give it a custom id or class and add your code in a separate .js file or through a custom code plugin.

Additionally, all fields have support for some global HTML attributes that all major browsers support.

AttributeExamplesDescription
autocompleteautocomplete="on"
autocomplete="off"
Defines if field can be automatically completed by the browser.
Optional.
autocorrectautocorrect="on"
autocorrect="off"
Defines if automatic spelling correction and processing of text is enabled while the user is editing this field.
Optional.
disableddisabled="disabled"Defines that the user cannot modify the value of the field. Some browsers prevent the user from clicking or selecting disabled fields.
Optional.
readonlyreadonly="readonly"Defines that the user cannot modify the value of the field. Read only fields can be clicked or selected by the user.
Optional.
spellcheckspellcheck="true"
spellcheck="false"
spellcheck="default"
Defines if field is subject to spell-checking by the underlying browser or Operating System (OS).
Optional.
titletitle="Text"Defines a text representing advisory information related to the field.
Optional.