Solved

jquery cross-slide

Posted on 2013-07-02
5
515 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
  • 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

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
how can i get the string decoded ? 2 28
Add shadow behind div 5 25
how can i turn the array into an object 4 40
JQuery Autocomplete Tag AJAX (Need nice script) 11 34
There are a couple ways to attach a JavaScript function to dynamically created elements. You can make a new script for each element as it’s created or you can use delegation. Delegation allows a single script that is added at page creation to mat…
Introduction If you're like most people, you have occasionally made a typographical error when you're entering information into an online form.  And to your consternation, the browser remembers the error, and offers to autocomplete your future entr…
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)
The viewer will learn the basics of jQuery including how to code hide show and toggles. 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…

808 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