Solved

jquery cross-slide

Posted on 2013-07-02
5
518 Views
Last Modified: 2013-07-03
Hello Experts,

I am using the cross-slide jquery plugin (https://github.com/tobia/CrossSlide/blob/master/HOWTO.md).

My question is what if you have two slideshows in one page? How can it work with multiple slideshows?

This is how i use it as they explain:

$('#slideshow').crossSlide({
  sleep: 2,
  fade: 1
}, [
  { src: 'sand-castle.jpeg' },
  { src: 'sunflower.jpeg'   },
  { src: 'flip-flops.jpeg'  },
  { src: 'rubber-ring.jpeg' }
]);

Open in new window

0
Comment
Question by:Refael
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 9

Expert Comment

by:TvMpt
ID: 39292473
What if you change only the id?? Just creat two block-level element (such as a div) and give them ID slideshow1 and slideshow2

$('#slideshow1').crossSlide({
  sleep: 2,
  fade: 1
}, [
  { src: 'sand-castle.jpeg' },
  { src: 'sunflower.jpeg'   },
  { src: 'flip-flops.jpeg'  },
  { src: 'rubber-ring.jpeg' }
]);

$('#slideshow2').crossSlide({
  sleep: 2,
  fade: 1
}, [
  { src: 'sand-castle.jpeg' },
  { src: 'sunflower.jpeg'   },
  { src: 'flip-flops.jpeg'  },
  { src: 'rubber-ring.jpeg' }
]);

Open in new window

0
 

Author Comment

by:Refael
ID: 39292491
TvMpt thak you for your reply.

I have tried it. for some reason it cause a conflict and it stops working.
If i knew for sure that this method should work fine i would have debug my script :-)
0
 
LVL 9

Assisted Solution

by:TvMpt
TvMpt earned 200 total points
ID: 39292544
If you send us the live site maybe we can help more :D
0
 
LVL 43

Accepted Solution

by:
Chris Stanyon earned 300 total points
ID: 39292723
If you look through the readme you will see that the author has acknowledged that this is from 2007 and as such is 'obsolete' - his advice is to use a different image slider, built on more up-to-date technology.

Don't waste any more time on a plug-in that is no longer supported. There are plenty of other, more modern ones out there.
0
 

Author Comment

by:Refael
ID: 39296130
Hi ChrisStanyon,

Really? No i haven't read the read-me file. There are so many going about this plugin in the NET that i was sure it is supported and up-to-date. 2007. Yes on some later projects i am working with the jQuery Cycle plugin which is really good too :-) Thank you for seeing that.
0

Featured Post

Optimize your web performance

What's in the eBook?
- Full list of reasons for poor performance
- Ultimate measures to speed things up
- Primary web monitoring types
- KPIs you should be monitoring in order to increase your ROI

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction Knockoutjs (Knockout) is a JavaScript framework (Model View ViewModel or MVVM framework).   The main ideology behind Knockout is to control from JavaScript how a page looks whilst creating an engaging user experience in the least …
Introduction JSON is an acronym for JavaScript Object Notation.  It is a text-string data transport mechanism, capable of representing simple or complex data structures in a consistent and easy-to-read manner.  Similar in concept to XML, but more e…
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
Suggested Courses

617 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question