- This topic is empty.
Viewing 1 post (of 1 total)
Viewing 1 post (of 1 total)
- The forum ‘JavaScript’ is closed to new topics and replies.
The forums ran from 2008-2020 and are now closed and viewable here as an archive.
Home › Forums › JavaScript › Two functions – Work individually, not together!
The following problem relates to this page:
http://www.burndenaces.co.uk/rumourmill
On the right hand side of the page, there are a series of images that scroll through using the innerfade function.
However, I am trying to get the page to refresh automatically every so often through AJAX using this code:
$(function(){
getFresh();
var int = setInterval(“getFresh()”, 15000);
});
Both of these work fine indivually but when I try to use both, the innerfade stops working. I’ve tried messing around but in truth, I’m just stuck on what to do next in order to get them both working together.
I came up with this, but it was just guess work and doesn’t work:
function getinnerFade() {
$(‘.fader’).innerfade({
animationtype: ‘fade’,
speed: 3000,
timeout: 8000,
type: ‘sequence’,
containerheight: ‘294px’
});
};
$(function(){
getFresh();
var int = setInterval(“getFresh()”, 15000);
getinnerFade();
});
Does anyone know where I’m going wrong and needs doing to fix it? Thanks.