0

Hi all,

I'm using AJAX to reload a div within my script. However it frequently causes the browser to crash. It's happened on two different local environments and I've only been able to test using chrome. Chrome presents this screen: http://i.imgur.com/wq2v7SJ.png

The code used to reload the div is:

<script type="text/javascript">

jQuery(document).ready(function() {
           reloadResponses();

});

function reloadResponses() {
            $('#responses').load('loadcomments.php?id=<?php echo $id;?>&creatorid=<?php echo $topicInfo['id']; ?>');                    
        }

setInterval(reloadResponses, 4000);
</script>

Does anyone know how to resolve this issue?

Edited by mmcdonald

1
Contributor
1
Reply
11
Views
4 Years
Discussion Span
Last Post by mmcdonald
0

Just an update - a friend believes this could be down to not releasing resources such as system memory causing it to build up and then crash the browser tab. But chrome seems to be a a steady 138MB - does this sound likely?

Apart from reloading the file containing the code - is there anything else I should be doing/releasing/closing etc?

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.