Response title
This is preview!
ajax('page.php', onCompletion);
function onCompletion () {
// Update here your DOM
setTimeout(function () {
myScroll.refresh();
}, 0);
};
2. Tabs plugin call (https://jqueryui.com/tabs/)
//Switch between tabs menu
$( "#tabs" ).tabs({
});
I want the slide to stay open when toggled and add a cookie to remember the state.
e.g.
$('#simple-menu').sidr({ side: 'left' // By default });
Any ideas on how to do this please? the following are the open
and close
calls.
//close
$.sidr('close', 'sidr-main');
// Open
$.sidr('open', 'sidr-main');
I have found an example online and tried to modify this http://jsfiddle.net/7m7uK/ but failing. Ive taken the cookie code from JSFiddle and tried to add in the Sidr plugin call. so confused. Any help would be greatly appreciated.
$('#simple-menu').sidr({ side: 'left' // By default }); // Open / Close Panel According to Cookie // if ($.cookie('panel') == 'open'){ $.sidr('open', 'sidr'); } else { $.sidr('close', 'sidr'); } $('#aaa').click(function(){ if ($(this).is(':hidden')) { $.cookie('panel', 'closed'); } else { $.cookie('panel', 'open'); } });
Thanks
Nick
© 2013 jQuery Foundation
Sponsored by and others.