예제 #1
0
def avatar(user, size=80):
    if not appsettings.ENABLE_AVATARS:
        return ''
    url = avatar_for_email(user.email, size)
    alt = escape(_('Avatar for %s') % get_user_display(user, False))
    return """<img src="%s" alt="Avatar for %s" height="%s" width="%s"/>""" % (
        url, alt, size, size
    )
예제 #2
0
def avatar(user, size=80):
    url = avatar_for_email(user.email, size)
    alt = escape(_('Avatar for %s') % get_user_display(user, False))
    return """<img src="%s" alt="Avatar for %s" height="%s" width="%s"/>""" % (
        url, alt, size, size)
예제 #3
0
def avatar(user, size=80):
    url = avatar_for_email(user.email, size)
    alt = escape(_('Avatar for %s') % get_user_display(user, False))
    return """<img src="%s" alt="Avatar for %s" height="%s" width="%s"/>""" % (
        url, alt, size, size
    )