[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

jQuery cycle images not fading

Posted on 2009-03-28
4
Medium Priority
?
1,097 Views
Last Modified: 2012-05-06
I'm trying to set up a slide show using the Cycle plugin: http://www.malsup.com/jquery/cycle/begin.html

The page loads and only one image displays but the effect does not happen.  The script I'm testing with does not fade.  Nothing happens.  I'm thinking there has to be a problem with my code.

Any ideas on what is wrong?
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<title>SIYOL</title>
	<meta http-equiv="content-type" content="text/html;charset=UTF-8" />    
	<script type="text/javascript" src="js/jquery.js"></script>
    <script type="text/javascript" src="js/jquery.cycle.all.min.js"></script>
    
	<style type="text/css" >
	.pics {  
    height:  200px;  
    width:   200px;  
    padding: 0;  
    margin:  0;  
    position: relative;
} 
 
.pics img {  
    padding: 15px;  
    border:  1px solid #ccc;  
    background-color: #eee;  
    width:  200px; 
    height: 200px; 
    top:  0; 
    left: 0 
} 
	
	</style>
	<script type="text/javascript">
	    $(document).ready(function() {
	        $('#s1').cycle('fade');
	    });
</script> 
	</head> 
	<body>
	<div id="s1" class="pics"> 
    <img src="images/01.jpg" width="200" height="200" /> 
    <img src="images/02.jpg" width="200" height="200" /> 
    <img src="images/03.jpg" width="200" height="200" /> 
</div> 
	
	</body>
</html>

Open in new window

0
Comment
Question by:PIER117
[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
4 Comments
 
LVL 16

Expert Comment

by:anoyes
ID: 24011171
I don't see anything obvious.  Do you get any JS errors?  What browser?  And is the page available somewhere I can see it?
0
 
LVL 1

Author Comment

by:PIER117
ID: 24011218
IE, Chrome, Firefox

How do I check for JS errors?

http://tiny.cc/MEvKZ 


0
 
LVL 16

Accepted Solution

by:
anoyes earned 500 total points
ID: 24011437
I think I found your problem.  The cycle plugin requires jQuery v. 1.2.6 or higher, but you've got v 1.2.3.  Try upgrading your version of jQuery and see if that solves the problem.

RE checking for JS errors, in Firefox at least you can grab either the Web Developer (https://addons.mozilla.org/en-US/firefox/addon/60) or Firebug (https://addons.mozilla.org/en-US/firefox/addon/1843) plugins, and in IE there's the Microsoft Script Debugger (http://www.microsoft.com/downloadS/details.aspx?familyid=2F465BE0-94FD-4569-B3C4-DFFDF19CCD99&displaylang=en)
0
 
LVL 1

Author Closing Comment

by:PIER117
ID: 31563955
Bingo!  That was it.  Works like a charm now.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying 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

SASS allows you to treat your CSS code in a more OOP way. Let's have a look on how you can structure your code in order for it to be easily maintained and reused.
CSS is a visual language used to classify objects and define rules about how they should be displayed. CSS skills aren’t restricted to developers anymore, there is a big benefit to having a basic understanding of the language, regardless of your occ…
In this tutorial viewers will learn how add a scalable full-width header using CSS3. Create a new HTML document with an internal stylesheet. Set a tiled background.:  Create a new div and name it Header. Position it with position:absolute at the top…
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.
Suggested Courses

649 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