method

xml_name_escape

Importance_1
v7.1.3.2 - Show latest stable - 0 notes - Class: ERB::Util
xml_name_escape(name) public

A utility method for escaping XML names of tags and names of attributes.

xml_name_escape('1 < 2 & 3')
# => "1___2___3"

It follows the requirements of the specification: www.w3.org/TR/REC-xml/#NT-Name

Show source
Register or log in to add new notes.