I have a button which sets a CSS height which I need to keep the same even after page refreshes. Here is the code:
<script>
function changeHeight(){
$('#totalInfo').css('marginTop', '172px');
$('.single #secondary-two #cart').css('maxHeight', '290px');
}
</script>
<button onClick="changeHeight()">Change Height</button>
The problem is, I've never dealt with cookies before and have no idea how to set one and then read it when a page is loaded. Anyone able to help me out on how to use jquery cookies to ensure the CSS height stays the same even after refreshes?
Thanks