示例#1
0
def obfuscate_mailto(value, text=False):
    """Obfuscates a mailto link
    """
    from htk.utils.obfuscate import html_obfuscate_string
    email = html_obfuscate_string(value)

    if text:
        link_text = text
    else:
        link_text = email

    result = '<a href="%s%s">%s</a>' % (
        html_obfuscate_string('mailto:'),
        email,
        link_text,
    )
    return result
示例#2
0
def obfuscate_mailto(value, text=False):
    """Obfuscates a mailto link
    """
    from htk.utils.obfuscate import html_obfuscate_string
    email = html_obfuscate_string(value)

    if text:
        link_text = text
    else:
        link_text = email

    result = '<a href="%s%s">%s</a>' % (
        html_obfuscate_string('mailto:'),
        email,
        link_text,
    )
    return result
示例#3
0
def obfuscate(value):
    """Obfuscates a string
    """
    from htk.utils.obfuscate import html_obfuscate_string
    result = html_obfuscate_string(value)
    return result
示例#4
0
def obfuscate(value):
    """Obfuscates a string
    """
    from htk.utils.obfuscate import html_obfuscate_string
    result = html_obfuscate_string(value)
    return result