1
jQuery-요소에 클래스가있는 경우이를 수행
요소에 특정 클래스가 있는지 확인하고 위치 변경과 같은 작업을 수행하는 jQuery 스크립트가 필요합니다. 이것은 방법이지만 이것이 작동하지 않을 것이라고 생각합니다. $("a.contact").toggle(function() { $("#contact").animate({ right: '0' }, 2000); if ($("#about").hasClass("opened")) { $("#about").animate({ right: -700 + "px" }, 2000); } }, function() { $("#contact").animate({ right: -700 + "px" }, 2000); });
111
javascript
jquery