码迷,mamicode.com
首页 > 其他好文 > 详细

mono下使用ajax控件报Details: Error parsing near错误

时间:2014-09-21 13:30:20      阅读:181      评论:0      收藏:0      [点我收藏+]

标签:http   io   os   使用   ar   for   文件   div   sp   

centOS-6.5 + mono-3.6+jexus-3.6.1

使用ajax控件时,在windows iis下没有问题,linux 下报如下错误

行: 16
错误: Sys.WebForms.PageRequestManagerParserErrorException:
The message received from the server could not be parsed.
Common causes for this error are when the response is modified by calls to Response.Write(),
response filters, HttpModules, or server trace is enabled.
Details: Error parsing near ‘v>
                           
</div>|6‘.

试着在page 上加  EnableEventValidation="false"  ValidateRequest="false" 不起作用,在web.config加  <httpRuntime requestValidationMode="2.0"/> <pages validateRequest="false" > 问题依旧

后来打开页面源文件发现有中文乱码,查看web.config <globalization/>字符配置 为gb2312

修改为utf-8 : <globalization requestEncoding="utf-8" responseEncoding="utf-8"  />

再次调试问题解决。不过又出现一个问题就是页面中文全是乱码。

在page页面添加  <meta charset="utf-8" /> 再次调试乱码消失

mono下使用ajax控件报Details: Error parsing near错误

标签:http   io   os   使用   ar   for   文件   div   sp   

原文地址:http://www.cnblogs.com/qingwa008/p/3984400.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!