Jquery Ajax refresh not working in IE.
- by Probocop
Hi, I have a <ul> which refreshes every ten seconds to check if there have been any new tweets (its pulling from a twitter feed). This works fine in Firefox and Chrome etc, but it does not work in any version if Internet Explorer.
My code is as follows:
setInterval(function() {
$("#banter .scroll-pane").load(location.href+" #banter .scroll-pane>*","");
}, 10000);
My PHP function creating the list is as follows:
function showTweets($section, $limit, $class) {
$result = mysql_query("SELECT * FROM hash WHERE section = '".$section."' ORDER BY date DESC LIMIT ".$limit);
echo '<ul class="scroll-pane '.$class.'">';
while($row = mysql_fetch_array($result)) {
echo '<li>';
echo '<p>'.html_entity_decode($row['tweet']).'</p>';
echo '<a href="'.$row['user_url'].'">'.$row['user'].'</a>';
echo '</li>';
}
echo '</ul>';
}
Any idea what's going wrong?
Thanks