set_placeholder()

Initial value selected if no other selection is made.

Signature:

public function set_placeholder(string $placeholder = ' ', bool $allowClear = true)

Parameters:

  • $placeholder: Placeholder text, e.g. “Please make a selection:”
  • $allowClear: Whether to display a clear button “x” to clear the select box back to the placeholder value once a selection is made.

No related content found.

Tags: