Y
Yann.PETIT
Hello everybody,
I'm currently serving XML or EDI files through a servlet.
I'd like to have a download function, I mean whan the user clicks on a
button it opens the "save as" window.
Unfortunately, XML is automatically recognized by IE and it displays it
without prompting whether I'd like to view it or saveit.
And I have the same king of problem with EDI files, they are in plain
text format so they are just displayed and not downloaded through the
"save as" window.
I've tried to play with mime types, and I found that if the mime type
isn't recognized by my browser it allows to save the file. But the
default file name is set to "myservlet.do" .
QUESTION: Is there a specific mime type for EDI ?
QUESTION: Is there another mime type than text/xml which would allow me
to let my xml flow be downloadable instead readable.
QUESTION: Is there a way to change the default name when downloading a
file (changing http headers may be but which one and how ?)
Many thanks by advance.
Yann
I'm currently serving XML or EDI files through a servlet.
I'd like to have a download function, I mean whan the user clicks on a
button it opens the "save as" window.
Unfortunately, XML is automatically recognized by IE and it displays it
without prompting whether I'd like to view it or saveit.
And I have the same king of problem with EDI files, they are in plain
text format so they are just displayed and not downloaded through the
"save as" window.
I've tried to play with mime types, and I found that if the mime type
isn't recognized by my browser it allows to save the file. But the
default file name is set to "myservlet.do" .
QUESTION: Is there a specific mime type for EDI ?
QUESTION: Is there another mime type than text/xml which would allow me
to let my xml flow be downloadable instead readable.
QUESTION: Is there a way to change the default name when downloading a
file (changing http headers may be but which one and how ?)
Many thanks by advance.
Yann