Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- M = imaplib.IMAP4()
- M.login('et403@live.mdx.ac.uk', '[my university password]')
- M.select()
- typ, data = M.search(None, 'ALL')
- for num in data[0].split():
- typ, data = M.fetch(num, '(RFC822)')
- print 'Message %s\n%s\n' % (num, data[0][1])
- M.close()
- M.logout()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement