2009-09-07 1 views
0

jCarousel 플러그인 사이트에는 순환 슬라이드 쇼를 수행하는 방법에 대한 예가 있지만 동적으로 생성 된 콘텐츠를 사용하고 있습니다. 나는 정적 컨텐츠로 어떻게 똑같은 일을 할 수 있는지 알고 싶다. 내가가 때 보여주는에서 이전 및 다음 버튼을 방지 할 수있는 방법, 정기적으로 업데이트받을 것입니다 사이트에이 일을하고 있습니다 때문에, 또한
http://sorgalla.com/projects/jcarousel/examples/special_circular.htmljCarousel과 정적 컨텐츠로 원형 회전식 컨베이어를 어떻게 만드나요?

:

여기에 동적 콘텐츠를 사용하여 jCarousel 원형 예제 보여줄 목록 항목이 3 개뿐입니까?

답변

0

이 예는 동적 콘텐츠를 사용하지 않고 정적 콘텐츠를 사용하고 있습니다. 로드중인 이미지 목록은 다음과 같습니다.

var mycarousel_itemList = [ 
    {url: 'http://static.flickr.com/66/199481236_dc98b5abb3_s.jpg', title: 'Flower1'}, 
    {url: 'http://static.flickr.com/75/199481072_b4a0d09597_s.jpg', title: 'Flower2'}, 
    {url: 'http://static.flickr.com/57/199481087_33ae73a8de_s.jpg', title: 'Flower3'}, 
    {url: 'http://static.flickr.com/77/199481108_4359e6b971_s.jpg', title: 'Flower4'}, 
    {url: 'http://static.flickr.com/58/199481143_3c148d9dd3_s.jpg', title: 'Flower5'}, 
    {url: 'http://static.flickr.com/72/199481203_ad4cdcf109_s.jpg', title: 'Flower6'}, 
    {url: 'http://static.flickr.com/58/199481218_264ce20da0_s.jpg', title: 'Flower7'}, 
    {url: 'http://static.flickr.com/69/199481255_fdfe885f87_s.jpg', title: 'Flower8'}, 
    {url: 'http://static.flickr.com/60/199480111_87d4cb3e38_s.jpg', title: 'Flower9'}, 
    {url: 'http://static.flickr.com/70/229228324_08223b70fa_s.jpg', title: 'Flower10'} 
]; 

해당 페이지의 코드에 대한 효과는 어떻습니까?

당신은 코멘트를 혼동하는 경우 :에, last :

jQuery(document).ready(function() { 
    jQuery('#mycarousel').jcarousel({ 
     wrap: 'circular', 
     itemVisibleInCallback: {onBeforeAnimation: mycarousel_itemVisibleInCallback}, 
     itemVisibleOutCallback: {onAfterAnimation: mycarousel_itemVisibleOutCallback} 
    }); 
}); 
+0

내 콘텐츠가 동적으로로드되지 않을 때 원형 회전식 컨베이어를 어떻게 얻을 수 있는지 알 수 없습니다. 내가 업데이트하는 사이트는 단순한 회전식 예와 같이 더 코딩되어 있습니다. http://sorgalla.com/projects/jcarousel/examples/static_simple.html 순서가 지정되지 않은 목록이며 각 목록 항목에는 헤더, 기술적 인 단락 및 이미지 또는 두. 간단한 회전 목마는 잘 작동하지만 나에게는 회전식 회전식 회전을하는 방법을 알 수 없습니다. –

+0

링크 된 페이지에 예제처럼 컨텐츠가로드되도록 사이트를 변경할 수 있습니까? –

+0

흠 ... 나는 마크 업과 자바 스크립트를 너무 많이 바꾸지 않으려 고했다. 그렇다면 순환 캐로 셀은 콘텐츠가 동적으로로드 된 경우에만 가능합니다. –

0

그냥 랩 추가

<!-- The content will be dynamically loaded in here --> 

모든 뜻이 회전 목마가이 코드에 의해 페이지로드에서 시작한다는 것입니다 루프를 만드는 init 함수.

+0

@ Jean-Michael 포장 : '마지막'이 올바르지 않습니다. 그런 다음 다음 회전 항목을 부드럽게 표시하지 않고 첫 번째 항목으로 돌아 가기 위해 신속하게 "뒤로 스크롤"하므로 원형 회전식 컨체인지가 아닙니다. – Arcadian