Can someone help me customize an existing code sample?
I can see from the following article how to connect to gmail and download content, but I can\'t figure out how to
import imaplib
from datetime import datetime, timedelta
obj = imaplib.IMAP4_SSL('imap.gmail.com',993)
obj.login('username','password')
obj.select()
today = datetime.today()
cutoff = today - timedelta(days=5)
dt = cutoff.strftime('%d-%b-%Y')
typ, data = obj.search(None, '(SINCE %s) (FROM "Alerts@foobank.com")'%(dt,))
print data