Android 当数据来自服务器时,为什么数据开始水平滚动?
我正在处理jquery和jquery mobile。我面临一个简单但太复杂的问题。我有一个div,在其中附加我的服务器数据。 在那个div中,我插入了样式(宽度示例40%),当我插入静态数据时,它工作正常,换句话说,当宽度完成时,数据进入新行。 但当来自服务器的数据开始水平滚动时。 举个例子,如果我有静态数据。 数据是这样的Android 当数据来自服务器时,为什么数据开始水平滚动?,android,jquery,css,jquery-mobile,cordova,Android,Jquery,Css,Jquery Mobile,Cordova,我正在处理jquery和jquery mobile。我面临一个简单但太复杂的问题。我有一个div,在其中附加我的服务器数据。 在那个div中,我插入了样式(宽度示例40%),当我插入静态数据时,它工作正常,换句话说,当宽度完成时,数据进入新行。 但当来自服务器的数据开始水平滚动时。 举个例子,如果我有静态数据。 数据是这样的 console.log("result"+result); 08-15 21:32:20.898: I/Web Console(5635): result&
console.log("result"+result);
08-15 21:32:20.898: I/Web Console(5635): result A. {mrr} distanced himself in May of 2010 following the prohibited practice.
08-15 21:32:20.898: I/Web Console(5635): :876
08-15 21:32:20.906: D/CordovaLog(5635):
var data = result.replace(" ", " ");
console.log("After result"+result);
After result A. {mrr} distanced himself in May of 2010 following the prohibited practice.
08-15 21:32:20.906: I/Web Console(5635): After result A. {mrr} distanced himself in May of 2010 following the prohibited practice.
嗨,这里是演示不,我会来的
第二天早上 但当数据来自服务器时,它显示为thsi 嗨,这是演示(见这里,你可以滚动你的数据)不,我明天早上来 我在android中面临这个问题 这是我的密码
<div id="test" style="width:40%"></div>
我从服务器上得到的结果如下
console.log("result"+result);
08-15 21:32:20.898: I/Web Console(5635): result A. {mrr} distanced himself in May of 2010 following the prohibited practice.
08-15 21:32:20.898: I/Web Console(5635): :876
08-15 21:32:20.906: D/CordovaLog(5635):
var data = result.replace(" ", " ");
console.log("After result"+result);
After result A. {mrr} distanced himself in May of 2010 following the prohibited practice.
08-15 21:32:20.906: I/Web Console(5635): After result A. {mrr} distanced himself in May of 2010 following the prohibited practice.
在您的服务器返回之前,是否将空格替换为
(读取非中断空格)?我将粘贴从服务器获得的内容。.等等,这是您的问题。您需要服务器不使用替换空格。这是服务器问题吗?我们不能在java脚本文件中执行任何操作?可以,但使用javascript修复它是倒退的。regexp可以用javascript来修复它,但除非我完全无法访问服务器代码,否则我不会这样做。