Method: str::html

Converts a string to a html-safe string

Info

Syntax

str::html($string, $keep_html=true)

Parameters

Return (string)

The html string

Example


echo str::html('some <em>über crazy</em> stuff');
// output: some <em>&uuml;ber crazy</em> stuff

echo str::html('some <em>über crazy</em> stuff', false);    
// output: some &lt;em&gt;&uuml;ber crazy&lt;/em&gt; stuff