Responsive navigation - how to get the nav to open/close, when browser is minimized
问题 I am making my own responsive navigation from this tut: http://www.hongkiat.com/blog/responsive-web-nav/ This is my fiddle: http://jsfiddle.net/2Pqch/ When window is minimized and you press the open/close btn I would like to be able to close it either by clicking the button or by clicking outside the nav. How can this function be added? Here is the script: $(function() { var pull = $('.btn'); menu = $('nav ul'); menuHeight = menu.height(); $(pull).on('click', function(e) { e.preventDefault();