Auto content type identification and output directory creation

The first commit ( ccad9d0 ) in this pull request adds auto content type identification for HTTP (GET response/POST requests) and for all email protocols (POP3/IMAP/SMTP).

Second commit ( f53347a ) takes care of auto creating the output directory in case it is not already created.