Drupal 上的 jCarousel
我的 Drupal-6 网站上有 jCarousel 模块。在我的页面上,我有以下代码:
<?php
$items = array (
0 => '<img src="http://dummyimage.com/100x100/000/fff&text=Bio" />',
1 => '<img src="http://dummyimage.com/100x100/000/fff&text=Bio" />',
....
);
$options = array (
'wrap' => 'circular',
'auto' => '5',
);
print theme('jcarousel', $items, $options);
?>
问题是当页面最初加载时,它将图像加载到列表中,然后将它们放入轮播中。我怎样才能使图像直接加载到轮播中而不是首先显示为列表?
I have the jCarousel module on my Drupal-6 website. On my page I have the following code:
<?php
$items = array (
0 => '<img src="http://dummyimage.com/100x100/000/fff&text=Bio" />',
1 => '<img src="http://dummyimage.com/100x100/000/fff&text=Bio" />',
....
);
$options = array (
'wrap' => 'circular',
'auto' => '5',
);
print theme('jcarousel', $items, $options);
?>
The problem is the when the page originally loads, It loads the images in a list and then puts them into a carousel. How can I make it so that the images load directly into a carousel instead of displaying as a list first?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在没有看到实际的完整代码的情况下,我猜测一个简单的“溢出:隐藏”可以解决问题。
据我所知,轮播项目始终需要位于列表中,您只是不希望它们在加载时显示在容器之外?
Without seeing the actual full code, I'm guessing a simple 'overflow:hidden' could solve the problem.
As far as I know the carousel items always need to be in a list, you just don't want them to display outside of the container while loading?