jquery - If div becomes larger then a specific height, make it static? -
i have div height controlled jquery. have script expands height ("show more"). problem is, div set position: fixed;
, when expand enough content outside window, cant see it.
what jquery script makes div static , not fixed when expands outside window.
#left { width: 250px; height: auto; margin-top: 167px; position: fixed; float: left; }
i have no idea how write this.
thanks in advance! have nice day.
edit: forgot, i'll post expand jquery function if needed, didn't think so.
something this:
$('#left').css('position', 'static');
or better:
$('#left').toggleclass('expanded');
with css:
#left.expanded {position: static;}
Comments
Post a Comment