
September 29th, 2012, 04:25 PM
|
 |
For POny!
|
|
Join Date: Apr 2012
Location: Amsterdam
|
|
Hi I am not sure If i quite understand you, but don't you mean if someone hovers over a menu item the image changes instead of clicking. Clicking will initiate a new page to be loaded.
Also the problem is that your menu links do not have something that makes them unique link and id to target them with jquery in a consistent way. ie
Code:
<a href="#" id="lessons">lessons</a>
in jquery you could than do the following.
Code:
$(document).ready(function(){
$('#lessons, #aboutus').hover(function() {
var name = $(this).attr('id');
$("#nivoSlider").css("background-image", name+".jpg");
});
});
Code is not tested but should give an idea
Last edited by aeternus : September 29th, 2012 at 04:34 PM.
|