You are here

public function Escaper::escapeHtml in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/zendframework/zend-escaper/src/Escaper.php \Zend\Escaper\Escaper::escapeHtml()

Escape a string for the HTML Body context where there are very few characters of special meaning. Internally this will use htmlspecialchars().

Parameters

string $string:

Return value

string

File

vendor/zendframework/zend-escaper/src/Escaper.php, line 146

Class

Escaper
Context specific methods for use in secure output escaping

Namespace

Zend\Escaper

Code

public function escapeHtml($string) {
  return htmlspecialchars($string, $this->htmlSpecialCharsFlags, $this->encoding);
}