JSON响应格式错误-响应前的红点\项目符号 [英] JSON response format error - red dot\bullet before response
问题描述
我正在发送一个期待JSON响应的AJAX请求. 但是,返回的JSON前面带有一个红色的dot \ bullet,这会引起解析错误.
I am sending an AJAX request expecting JSON response. However, the returned JSON is preceded with a red dot\bullet which is causing a parse error.
这是Postman
的屏幕截图:
该点不显示在Raw
或Preview
显示屏上,仅显示在Pretty
上.
The dot is not shown on Raw
or Preview
display, only on Pretty
.
在Chrome开发者工具的网络"标签中,它显示在Response
下. Preview
正常显示为好像该点不存在.
In Chrome Dev Tools Network tab it appears under Response
. Preview
is shown normally as if the dot isn't there.
推荐答案
如之前的评论中所述:在Chrome中,红点通常表示不可打印的特殊unicode字符.
As mentioned in a comment before: In Chrome, red dots usually represent non-printable special unicode characters.
请检查您的服务器端代码以防止输出这些字符
Please check your server side code to prevent outputting those characters
这篇关于JSON响应格式错误-响应前的红点\项目符号的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!