How to do remember choice image.
Hello,
I have this for a script to change the images in the background.
- $(document).ready(function(){
- $('#menu').click(function(){
- $('#thumb').slideToggle('slow');
- });
- $('li img').click(function(){
- var imgbg = $(this).attr('dir');
- $('body').css({backgroundImage: "url("+imgbg+")"});
- });
- $('#bgimage').click(function(){
- $('#thumb').hide();
- });
- });
It's just that after the change and refresh the page returns to its original state. Let us take to the selected image wyśiwietlał all the time (ie. selection remembered)?