Set Content-Type in MMS from Java

Set Content-Type in MMS from Java SearchSearch

SMS & MMS Technical Forum » NowSMS Support - MMS & Advanced Issues (Product Support Only) » Set Content-Type in MMS from Java « Previous || Next »
Author Message
Bryce Norwood - NowSMS Support
Board Administrator
Username: Bryce

Post Number: 8138
Registered: 10-2002
Posted on Tuesday, March 29, 2016 - 06:00 pm:   

From our support mailbox:


quote:

Hi

I need to send an MMS with png files as attachments.

I am using the java code from here: http://www.nowsms.com/doc/submitting-mms-messages/send-mms-message-with-java

However the attachment filenames are WITHOUT extension (.png) so it does not work using

addparameter(“MMSFile”,file) since that expects the correct extension.

Is there any way to set the content-type for an attachment?




Hi,

No, there is not.

Even if you modify the Java code to pass content-type as a parameter instead of relying on guessContentTypeFromName, for this interface, NowSMS would ignore it, and still expects to determine content-type based on the file extension.


-bn

Bryce Norwood
Now SMS/MMS Support

Add Your Message Here, or click here to create a new discussion topic.
Post:
Bold text Italics Underline Create a hyperlink Insert a clipart image
Posting Information:
This is a private posting area. Only registered users and moderators may post messages here.
Click here to create an account.
Username:
Password:
Options: Automatically activate URLs in message
Action:

Login Login / Register Logout Logout Search Last 30 Days Topics Topics