无法使用动态 ajax 数据重建超大幻灯片
我正在使用全屏背景库 Supersized 开发一个网站, 网站开始在页面加载时显示默认图库。它工作完美。
问题是当我尝试:
- 删除超大实例
使用ajax加载的其他数据重新加载新实例
var 选项 = { 进度条:1, 随机:1, Slide_interval : 3000, // 转换之间的长度 transition : 1, // 0-无、1-淡入淡出、2-幻灯片顶部、3-幻灯片右侧、4-幻灯片底部、5-幻灯片左侧、6-旋转木马右侧、7-旋转木马左侧 transition_speed : 700, // 转换速度 // 成分 Slide_links : 'blank', // 每张幻灯片的单独链接(选项: false、'number'、'name'、'blank') Slides : [ // 幻灯片图像 {图片:'http://spiaggiaolivi.webjuice.it/foto/galleria/sfondi/livedinnerparty_-07_1280x853.jpg',标题:'图片来源:Maria Kazvan'}, {图片:'http://spiaggiaolivi.webjuice.it/foto/galleria/sfondi/livedinnerparty_-08_1280x853.jpg',标题:'图片来源:Maria Kazvan'} ] } $(函数(){ $.supersized(选项); });
调用
// click
$('#gallery a.show').live('click', function(event){
$('body').append('<div id="supersized-loader"></div><ul id="supersized"></ul>');
var options3 = {
transition : 1, // 0-None, 1-Fade, 2-Slide Top, 3-Slide Right, 4-Slide Bottom, 5-Slide Left, 6-Carousel Right, 7-Carousel Left
transition_speed : 700, // Speed of transition
slides : [ // Slideshow Images
{image : 'http://spiaggiaolivi.webjuice.it/foto/galleria/galleria-3/bggal4.jpg', title : 'Image Credit: Maria Kazvan'},
{image : 'http://spiaggiaolivi.webjuice.it/foto/galleria/galleria-3/bggal5.jpg', title : 'Image Credit: Maria Kazvan'},
{image : 'http://spiaggiaolivi.webjuice.it/foto/galleria/galleria-3/bggal6.jpg', title : 'Image Credit: Maria Kazvan'},
]
}
$.supersized(options3);
“动态”实例由}
任何人都可以帮助我吗?
您可以在此处查看所有项目,然后导航到 FOTOGALLERY
I'm developing a website using fullscreen background library Supersized,
the website start show a default gallery on page load. It works perfectly.
The problem is when I try to:
- Remove the Supersized istance
Reload a new istance with other data loaded by ajax
var options = { progress_bar : 1, random : 1, slide_interval : 3000, // Length between transitions transition : 1, // 0-None, 1-Fade, 2-Slide Top, 3-Slide Right, 4-Slide Bottom, 5-Slide Left, 6-Carousel Right, 7-Carousel Left transition_speed : 700, // Speed of transition // Components slide_links : 'blank', // Individual links for each slide (Options: false, 'number', 'name', 'blank') slides : [ // Slideshow Images {image : 'http://spiaggiaolivi.webjuice.it/foto/galleria/sfondi/livedinnerparty_-07_1280x853.jpg', title : 'Image Credit: Maria Kazvan'}, {image : 'http://spiaggiaolivi.webjuice.it/foto/galleria/sfondi/livedinnerparty_-08_1280x853.jpg', title : 'Image Credit: Maria Kazvan'} ] } $(function(){ $.supersized(options); });
the "DYNAMIC" istance is called by
// click
$('#gallery a.show').live('click', function(event){
$('body').append('<div id="supersized-loader"></div><ul id="supersized"></ul>');
var options3 = {
transition : 1, // 0-None, 1-Fade, 2-Slide Top, 3-Slide Right, 4-Slide Bottom, 5-Slide Left, 6-Carousel Right, 7-Carousel Left
transition_speed : 700, // Speed of transition
slides : [ // Slideshow Images
{image : 'http://spiaggiaolivi.webjuice.it/foto/galleria/galleria-3/bggal4.jpg', title : 'Image Credit: Maria Kazvan'},
{image : 'http://spiaggiaolivi.webjuice.it/foto/galleria/galleria-3/bggal5.jpg', title : 'Image Credit: Maria Kazvan'},
{image : 'http://spiaggiaolivi.webjuice.it/foto/galleria/galleria-3/bggal6.jpg', title : 'Image Credit: Maria Kazvan'},
]
}
$.supersized(options3);
}
Anyone can help me?
You can see all the project HERE and than navigate into FOTOGALLERY
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
试试这个:
创建图像数组:
然后设置主页 Suppersize 幻灯片
然后创建其余的 Supersize 函数:
然后用您想要使用的数组调用该函数,无论您想要什么方法...即 onClick();
希望这有帮助;-)
编辑:我遇到的唯一问题是它搞砸了转换速度......我仍在努力解决这个问题!
Try this:
Create the Image Arrays:
Then set the home page Suppersize slideshow
Then create the rest Supersize function:
Then call the function with the array you want to use, from whatever method you want... i.e. onClick();
Hope this helps ;-)
EDIT: the only issue I have had with this is that it screws up the transition speeds.... Im still trying to work this issue out!