搜索 | 用户支持

防范以用户支持为名的诈骗。我们绝对不会要求您拨打电话或发送短信,及提供任何个人信息。请使用“举报滥用”选项报告涉及违规的行为。

Learn More

Firefox is add 'charset=UTF-8' to the content-type when using AJAX

  • 1 个回答
  • 21 人有此问题
  • 35 次查看
  • 最后回复者为 cor-el

more options

I am using XMLHttpRequest to send data to the server, and Firefox is adding 'charser=UTF-8' to the end of the content-type header attribute. I have tried to over write the content-type by adding "mypostrequest.setRequestHeader("Content-type", "application/x-www-form-urlencoded");" But 'charser=UTF-8' is still added.

This happened

Every time Firefox opened

I am using XMLHttpRequest to send data to the server, and Firefox is adding 'charser=UTF-8' to the end of the content-type header attribute. I have tried to over write the content-type by adding "mypostrequest.setRequestHeader("Content-type", "application/x-www-form-urlencoded");" But 'charser=UTF-8' is still added. == This happened == Every time Firefox opened

所有回复 (1)

more options

Try http://forums.mozillazine.org/viewtopic.php?p=6318215#p6318215

Please do not post in old topics. If you ned help then create a new post on the MozillaZine Web Development/Standards Evangelism forum. The helpers at that forum are more knowledgeable about web development issues. You need to register at the MozillaZine forum site in order to post at that forum. See http://forums.mozillazine.org/viewforum.php?f=25