douyou2368 2018-09-27 15:48
浏览 89

Jquery Ajax请求需要鼠标移动才能更新屏幕?

I have a fairly straight forward system which consists of one large screen showing the status of order numbers and a user screen (iPad) where they are changed.

Both are simple html/php pages and were working fine an hour ago.

The main screen is set to refresh every 3 seconds with the following code (this is the only actual script in this page).

$(document).ready(function() { 
    setInterval(timingLoad, 3000);
    function timingLoad() {
        $('#main').load('update_divs.php #main', function() {
        });
    }
}); 

This is all setup on a small standalone Linux pc running as a LAMP server with no internet access.

The refresh runs 3 very basic php SQL requests to populate the Div with current position.

According to the user it has been working fine all afternoon but now will not update unless the mouse is moved, as soon as the mouse has had any movement the screen immediately updates to the latest position. This is not at all ideal as there shouldn't even be a need for a mouse to be connected to the PC.

Is it possible that I'm refreshing the page too often and somehow causing a memory issue or is this some other issue that people are aware of?

I've told them to restart the PC when they get a chance and I feel (as I've not heard from them in last half hour) that this has resolved it but obviously it is possibly going to happen again if I can't resolve it.

Any thoughts?

  • 写回答

0条回答 默认 最新

    报告相同问题?

    悬赏问题

    • ¥30 python代码,帮调试
    • ¥15 #MATLAB仿真#车辆换道路径规划
    • ¥15 java 操作 elasticsearch 8.1 实现 索引的重建
    • ¥15 数据可视化Python
    • ¥15 要给毕业设计添加扫码登录的功能!!有偿
    • ¥15 kafka 分区副本增加会导致消息丢失或者不可用吗?
    • ¥15 微信公众号自制会员卡没有收款渠道啊
    • ¥100 Jenkins自动化部署—悬赏100元
    • ¥15 关于#python#的问题:求帮写python代码
    • ¥20 MATLAB画图图形出现上下震荡的线条