JQuery change background and keep it -


my jquery code looks this:

$(document).ready(function() {        $('.french').click(function(){ changebackground();      }); });  function changebackground(){     $("#title").css('backgroundposition', '0px -120px' ); } 

works beautifully 1 problem : after click background returns initial state. how can keep new background after click?

thanks ideas!

all working me thing can change this:

$(document).ready(function() {        $('.french').click(changebackground); });  function changebackground(){     $("#title").css('backgroundposition', '0px -120px' ); } 

here working example using jquery 1.5


Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -