Netscape/Mozilla (setting mime-types)

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
Chris Corbyn
Breakbeat Nuttzer
Posts: 13098
Joined: Wed Mar 24, 2004 7:57 am
Location: Melbourne, Australia

Netscape/Mozilla (setting mime-types)

Post by Chris Corbyn »

Hi,

Can I add mime-types to Netscape/Mozilla so that when an email is sent it has the correct content-type specified?

It must work for sending emails, not just viewing web content.

Thanks in advance :-)
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

yes you can. It's in your header settings when calling [php_man]mail()[/php_man]. Example 4 on the mail function page has an html email, which changes the content-type.
User avatar
Chris Corbyn
Breakbeat Nuttzer
Posts: 13098
Joined: Wed Mar 24, 2004 7:57 am
Location: Melbourne, Australia

Post by Chris Corbyn »

That isn't what I meant.... I was just talking about the actual preferences within Netscape/Mozilla browsers on the client side.

But, I also am considering writing a script with the mail() function to do the job. Just not sure how tricky it would be to allow attachments to be added? It's just for personal use you see :-)
User avatar
Chris Corbyn
Breakbeat Nuttzer
Posts: 13098
Joined: Wed Mar 24, 2004 7:57 am
Location: Melbourne, Australia

Post by Chris Corbyn »

Hmm... this would be ok (if it works)....

Can you use the mail() function to send an attachment (its a JAR file) with the content type specified but not as a multipart message? It would essentially be just sending a file through email without any text in the body...

Multipart messages are looking a bit complex to create
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

my bad. There's an option in the Mozilla preferences called Helper Applications that can add mime type handlers.
User avatar
Chris Corbyn
Breakbeat Nuttzer
Posts: 13098
Joined: Wed Mar 24, 2004 7:57 am
Location: Melbourne, Australia

Post by Chris Corbyn »

Thanks very much :-D Hope it works for sending emails using NS mail and not just for handling web page content (I need netscape to put content-type=aplication/x-java-archive instead of aplication/octet-stream) when |I attach a JAR file.

I'll test it when I get home from work.

Thanks again :wink:
Post Reply