body = """
Welcome %s,
Congratulations, you have just joined us.
Start using our site by click the link below:
%s
We hope that you enjoy!
Team.
恭喜妳/你已成為會員。
%s
希望妳能享受使用!
""".encode('utf-8') % (username, request_url, request_url)
mail.send_mail(sender=sender_address, to=email_address, subject=subject, body=body)
好的,这是我到目前为止所拥有的,但它不起作用。我该怎么做才能将 utf-8 编码为邮件 api 并使其适用于在一封电子邮件中使用多种语言?
提前致谢。