Some common utilities

Functions

f
date_to_string

Convert an ISO formatted date to a more readable format.

f
de_xml

Remove any XML/HTML tags from the input; <br/> tags are replaced by space and all other tags are removed.

f
remove_entities

Filter XML entities in an xhtml code, and turn them into their equivalent hexadecimal Unicode point

f
slice_text

“Slice” a long text into lines separated by the (HTML) <br/> tag. Used as a rudimentary tool when adding the title lines to an SVG content.

f
to_xhtml

Convert an HTML5 content (in text or as a DOM) into XHTML5.