I need to write a script to send an email using sendmail. The code that I'm looking at was found here: http://effbot.org/pyfaq/how-do-i-send-mail-from-a-python-script.htm
I am trying to figure out what this syntax means:
FROM = "sender@domain.ca"
TO = ["recipient@domain.ca"]
SUBJECT = "Hello!"
TEXT = "This message was sent via sendmail."
# Prepare actual message
message = """\
From: %s
To: %s
Subject: %s
%s
""" % (FROM, ", ".join(TO), SUBJECT, TEXT)
From what I can gather the triple quote is used when you need to create a very long string with keywords so that python doesn't try to interpret them. However the percentage used after the triple quote is what intrigues me. Is it some sort of concatenate operator like ampersand?