내 웹 사이트에 숨겨진 메뉴를 추가하려고합니다. 이것이 정확히 달성하고자하는 목표입니다. http://demo.themebeans.com/pinto/하지만 클릭 대신 마우스를 올리면됩니다. 그냥 클릭 대신
... 그냥 내 방문자가 그냥 마우스로 가리 키도록하십시오.
클릭하거나 마우스를 올렸을 때만 표시되는 숨겨진 메뉴를 추가하는 방법은 무엇입니까?
여기까지 제가 지금까지 있습니다. 위에 주어진 샘플과 동일하게 배치되기를 바랍니다. :(누군가가 도와 줄 수
#nav{width:200px;height:100%;position:absolute;top:0;left:0;z-index:100;background:#111;color:#fff;overflow:hidden;}
#nav ul{margin:0;padding:0;width:200px;margin:10px;list-style:none;}
#nav a span{margin:0 10px 0 0;}
#nav a{color:#fff;font-size:14px;text-decoration:none;}
jQuery를 :
$(function(){
$('#nav').hover(function(){
$(this).animate({width:'200px'},500);
},function(){
$(this).animate({width:'35px'},500);
}).trigger('mouseleave');
});
HTML :.
<div id="nav">
Contents of the sidebar like the one on my sample.
</div>
http://jsfiddle.net/yztJ8/ 여기 여기
덕분에 많이! 그것은 일했다! : D – missmisunderstood
안녕. 하지만 높이 자동 브라우저로 크기를 어떻게 조정합니까? http://shericaocbania.org/chiara/ – missmisunderstood
높이에 문제가 보이지 않습니다 ... 적어도 Chrome을 사용하면 크기를 조정할 때'height : 100 %'가 잘 작동합니다. –