util_expand_entities (public)

 util_expand_entities html

Defined in packages/acs-tcl/tcl/text-html-procs.tcl

Replaces all occurrences of common HTML entities with their plaintext equivalents in a way that's appropriate for pretty-printing.

Currently, the following entities are converted: <, >, &apm;quot;, &, — and —.

This proc is more suitable for pretty-printing that its sister-proc, util_expand_entities_ie_style. The two differences are that this one is more strict: it requires proper entities i.e., both opening ampersand and closing semicolon, and it doesn't do numeric entities, because they're generally not safe to send to browsers. If we want to do numeric entities in general, we should also consider how they interact with character encodings.

Parameters:
html

Partial Call Graph (max 5 caller/called nodes):
%3 ad_html_to_text_put_text ad_html_to_text_put_text (private) util_expand_entities util_expand_entities ad_html_to_text_put_text->util_expand_entities

Testcases:
No testcase defined.
[ show source ]
Show another procedure: