Hi, I'm building a site that relies heavily on jquery. I have three scripts I'm trying to use on the same page: a lavalamp-style menu, an area with draggable divs, and a content slider containing both elements that will allow me to scroll between content areas.
I can not get the content slider to function correctly. Links will take me to the other content areas, but the "sliding" effect doesn't function correctly unless I get rid of the lava lamp code. Is there some way I can tweak the javascript so that these three scripts can work together?
$(document).ready(function() {
$('a.panel').click(function () {
$('a.panel').removeClass('selected');
$(this).addClass('selected');
current = $(this);
$('#scroll-wrapper').scrollTo($(this).attr('href'), 800);
return false;
});
$(window).resize(function () {
resizePanel();
});
});
function resizePanel() {
width = $(window).width();
height = $(window).height();
mask_width = width * $('.item').length;
$('#debug').html(width + ' ' + height + ' ' + mask_width);
$('#scroll-wrapper, .item').css({width: width, height: height});
$('#mask').css({width: mask_width, height: height});
$('#scroll-wrapper').scrollTo($('a.selected').attr('href'), 0);
}
$(function() {
$("#3").lavaLamp({
fx: "backout",
speed: 700,
click: function(event, menuItem) {
return false;
}
});
$("#dragset div").draggable({ stack: { group: '#dragset div', min: 1 } });
});