This week's book giveaway is in the JavaScript forum.
We're giving away four copies of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js and have Paul Jensen on-line!
See this thread for details.
Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Error in Attachment file name  RSS feed

 
jim jjoh
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi below is my code

String fileName="XxxxxxxXxx_Sxxxxxxs.xls";(not real)
response.setContentType("application/vnd.ms-excel");
response.setHeader("Content-Disposition", "attachment; filename="+fileName);
return;

In IE7 the file name is getting appended with some junk charaters.
For IE8 and Firefox it is working correctly.
Did anybody know the reason?

From the trial and error method what I understand is ‘_S ‘is causing the problem.
If we change ‘_S’ to some other letters or append another letter in the end of filename this issue is not coming.

Is there any work around for this?Did anybody knows the reason for this?

Thanks
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!