weizi2012

          weizi2012

          jsp 文件下載,文件名稱中文顯示解決方法

          response.setCharacterEncoding("GBK");
           response.setContentType("application/x-download;charset=GBK");//設置為下載application/x-download
          String filenamedisplay = URLEncoder.encode(filenamedisplay, "UTF-8");//文件編碼問題 注意修改

          response.addHeader("Content-Disposition", "attachment;filename="
             + filenamedisplay);response.addHeader("Content-Disposition", "attachment;filename="
             + filenamedisplay);

          posted on 2012-09-27 11:00 jiangwei 閱讀(158) 評論(0)  編輯  收藏


          只有注冊用戶登錄后才能發表評論。


          網站導航:
           

          My Links

          Blog Stats

          常用鏈接

          留言簿

          隨筆檔案

          文章檔案

          搜索

          最新評論

          主站蜘蛛池模板: 丰都县| 大同县| 林周县| 临汾市| 静安区| 贡嘎县| 镇江市| 江油市| 永清县| 铜山县| 微山县| 越西县| 伊吾县| 丹东市| 清徐县| 昌黎县| 沙湾县| 银川市| 麟游县| 普定县| 遂溪县| 浦东新区| 杭锦后旗| 博兴县| 霍林郭勒市| 光山县| 涞水县| 黔江区| 含山县| 黄陵县| 建湖县| 陆川县| 彰武县| 岳阳县| 贺兰县| 绥中县| 陆河县| 景东| 闵行区| 北安市| 德州市|