Heray-Was-Here
Server : Apache
System : Linux dal-shared-66.hostwindsdns.com 4.18.0-513.24.1.lve.1.el8.x86_64 #1 SMP Thu May 9 15:10:09 UTC 2024 x86_64
User : krnuyqrm ( 1183)
PHP Version : 7.4.33
Disable Function : NONE
Directory :  /proc/thread-self/root/lib64/python2.7/site-packages/Cheetah/Utils/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //proc/thread-self/root/lib64/python2.7/site-packages/Cheetah/Utils/htmlDecode.py
"""This is a copy of the htmlDecode function in Webware.

@@TR: It implemented more efficiently.

"""

from Cheetah.Utils.htmlEncode import htmlCodesReversed


def htmlDecode(s, codes=htmlCodesReversed):
    """ Returns the ASCII decoded version of the given HTML string. This does
    NOT remove normal HTML tags like <p>. It is the inverse of htmlEncode()."""
    for code in codes:
        s = s.replace(code[1], code[0])
    return s

Hry