jQuery Acarousel.js Cover Flow Style Carousel Example
Acarousel.js is a tiny (3kb minified) jQuery plugin to create a cover flow style image carousel for the web.
제이쿼리 두개사용중인데 2번째제이쿼리 버튼 누르면 첫번째 버튼이먹힙니다
도와주세요 ㅠㅠ 초보입니다..
ㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡ









Acarousel.js is a tiny (3kb minified) jQuery plugin to create a cover flow style image carousel for the web.

var _gaq = _gaq || []; _gaq.push(['_setAccount', 'UA-36251023-1']); _gaq.push(['_setDomainName', 'jqueryscript.net']); _gaq.push(['_trackPageview']);
(function() { var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })();
답변을 작성하려면 로그인이 필요합니다.
로그인
$(function () {
var acarousel = $("#carousel").acarousel();
changeActive();
$("#carousel li a").click(function() {
if (acarousel.isAnim()) return false;
var move = acarousel.moveByElem($(this).parent());
if (move == 0) {
alert("Move 0");
} else {
changeActive(move);
}
return false;
});
$("#move_back").click(function () {
if (acarousel.isAnim()) return false;
var move = acarousel.move(1);
changeActive(move);
return false;
});
$("#move_next").click(function () {
if (acarousel.isAnim()) return false;
var move = acarousel.move(-1);
changeActive(move);
return false;
});
$(".move").click(function () {
if (acarousel.isAnim()) return false;
var index = $(".move").index(this);
var move = acarousel.moveByIndex(index);
changeActive(move);
return false;
});
function changeActive(move) {
var index = acarousel.getPos(move).index;
$(".move").removeClass("active").eq(index).addClass("active");
}
$(window).resize(function () {
var parent = $("#carousel_container");
var self = $("#carousel");
self.css({
left: parent.width() / 2 - self.width() / 2
, top: parent.height() / 2 - self.height() / 2
});
}).trigger("resize");
});
</script>
<div id="content">
<h1>jQuery Acarousel.js Cover Flow Style Carousel Example</h1>
<p>Acarousel.js is a tiny (3kb minified) jQuery plugin to create a cover flow style image carousel for the web.</p>
<p><a href="demo2.html">Check Out Advanced Demo</a></p>
<div id="carousel_container">
<ul id="carousel">
<li id="c1"><a href="#"><img src="img1.jpg"></a></li>
<li id="c2"><a href="#"><img src="img2.jpg"></a></li>
<li id="c3"><a href="#"><img src="img3.jpg"></a></li>
<li id="c4"><a href="#"><img src="img4.jpg"></a></li>
<li id="c5"><a href="#"><img src="img5.jpg"></a></li>
<li id="c6"><a href="#"><img src="img6.jpg"></a></li>
<li id="c7"><a href="#"><img src="img7.jpg"></a></li>
<li id="c8"><a href="#"><img src="img8.jpg"></a></li>
<li id="c9"><a href="#"><img src="img9.jpg"></a></li>
</ul>
</div>
<div id="move_mark">
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<div id="move_back"><a href="#">←</a></div>
<div id="move_next"><a href="#">→</a></div>
</div>
</div>
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-36251023-1']);
_gaq.push(['_setDomainName', 'jqueryscript.net']);
_gaq.push(['_trackPageview']);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();
</script>
----------------------------------------------------------------------------------
이부분입니다
<div id="move_mark">
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<a class="move" href="#">●</a>
<div id="move_back"><a href="#">←</a></div>
<div id="move_next"><a href="#">→</a></div>
</div>
좌우 동그라미누르면 자꾸 전제이쿼리인 위로가기가됩니다 ㅠㅠ