mime

How do I determine the extension(s) associated with a MIME type in PHP?

Is there a quick and dirty mapping of MIME types to extensions in PHP that I can make use of? ...

Unknown file type MIME?

Do I have to specify a MIME type if the uploaded file has no extension? In other words is there a default general MIME type? ...

Ruby Email Client Recommendation

We are writing an email web client in Ruby to handle (potentially international) emails. I am looking for a high-level email library that supports retrieving emails, parsing email raw, decoding MIME, and converting input into UTF-8. Is there a library that you can recommend? ...

Dynamic URL from WCF Web Service

I'm trying to serve up Excel documents that I have stored in a database via a WCF RSS feed (the user clicks a link in the feed and it sends down a specific Excel document). The Excel files aren't sitting in a directory any where (in which case I could just give each user a static URL). So what I'd like to do is have a dynamically ge...

Mime Headers and IIS 6 SMTP logging

Hi, Are there any Mime headers which will show up in the IIS 6 smtp logs? ...

Extracting the To: header from an attachment of an email

I am using python to open an email on the server (POP3). Each email has an attachment which is a forwarded email itself. I need to get the "To:" address out of the attachment. I am using python to try and help me learn the language and I'm not that good yet ! The code I have already is this import poplib, email, mimetypes oPo...

How do I use PHPMailer? Can't find a simple decent tutorial online!

Hi there, I'm trying to send out a Plain/HTML multipart email out and I'm currently using PHP's mail() function. Many people have recommended PHPMailer so I thought I'd give it a go. However, as everything seems to be nowadays, it appears very complicated. I downloaded it and it talks about installing it and configuring MySQL connectio...

Set MIME associations for MS Works

Hi all My website issues documents in .rtf and .doc format. One of my clients only has MS Works installed on his machine. It seems that his machine is attempting to open the documents in Notepad, which is far from ideal. The client does have MS Works installed, which would presumably make a better fist of displaying these documents. Do...

How can you read a files MIME-type in objective-c

I am interested in detecting the MIME-type for a file in the documents directory of my iPhone application. A search through the docs did not provide any answers. ...

PHP Regular Expressions (REGEX) Multipart MIME (NOT-EMAIL)

I'm trying to do a "preg match all" on the response below to get all the binary data. I've tried just about everything imaginable and for the life of me, can't get anything. I was hoping it'd be as simple as doing something like this: preg_match_all("#\n\n(.*)\n--$boundary#",$body,$matches); But I can't get anything. I've tried other...

Stop IE8 from opening or downloading a text/plain MIME type

I'm dynamically generating a text file in PHP, so it has a .php extension but a text/plain MIME type. All browsers display the file as nicely preformatted text, except IE8. Googling tells me that they've added security where if the HTTP header content type doesn't match the expected content type (I think based on the extension and some...

How to find which program to use for a given mime type in linux?

i need to open a viewer for a given mime type. how to do that in linux. i suppose the method would be specific to desktop environment in use. i want to do this through a C program. ...

Retrieving and parsing a MIME email from a database

Task given: An email is stored, byte for byte, in one or more chunks (of fixed length) in a database. This mail is to be retrieved from that database and it's contents shall be displayed to the user. I have no problem wrapping the legacy database in an ActiveRecord model, concatenating the stored chunks and so on. What I don't really kn...

Apple iWork Mime Types

I was wondering what the mime type for iWork's Pages is? And also what the mime type is for the rest of the software in the iWork suite? I looked around online and I didn't see it anywhere. Thanks! ...

How can I get an email message's text content using python?

Given an RFC822 message in Python 2.6, how can I get the right text/plain content part? Basically, the algorithm I want is this: message = email.message_from_string(raw_message) if has_mime_part(message, "text/plain"): mime_part = get_mime_part(message, "text/plain") text_content = decode_mime_part(mime_part) elif has_mime_part...

How do I get IE6 to take ContentType seriously?

I'm fighting with a third-party ActiveX control that we are using to load TIFF images into the client browser from an ASP.Net(3.5) web form. The ActiveX control registers itself correctly (as far as I can tell) as the MIME handler for TIFF images and works correctly every time a file is double-clicked locally. However, IE6 and the Acti...

Generate HTML e-mail with embedded images in Delphi

Anyone know of a good example of generating HTML e-mail with embedded images and an alternate text part? I need to generate some tabular reports in HTML and would like to embed logos and other images. I believe Indy can do this with some work, but I was hoping someone could point me to a good example as a starting point. I am open to us...

Register/Alter MIME associations in asp.net mvc Web Setup Project

I'm making a Web Setup Project of my Asp.net Mvc project. I'd like the installer to change some MIME associations on IIS7. How to do this? ...

File extensions and MIME Types in .NET

I want to get a MIME Content-Type from a given extension (preferably without accessing the physical file). I have seen some questions about this and the methods described to perform this can be resumed in: Use registry information. Use urlmon.dll's FindMimeFromData. Use IIS information. Roll your own MIME mapping function. Based on thi...

MIME and Processing Feedback Loop Messages

I'm trying to process Feedback Loop (FBL) messages to unsubscribe people that mark an email as spam (yes it's opt-in, and there is a one-click opt-out mechanism). My first attempt is to use Advanced MIME Parser/Creator/Editor. However, FBL messages from major ISPs such as AOL and Yahoo are not correctly parsed. I posted that particular...