escape::attr($string, $strict = false)

Escape common HTML attributes data

  • $string (string)
  • $strict (string)
    Whether to escape characters like [space] % * + , - / ; < = > ^ and | which is necessary in case of unquoted HTML attributes.
  • return (string)