SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Enthusiast
    Join Date
    Oct 2006
    Posts
    36
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Need help with Jquery Cycle Plugin

    My cycle plugin works in firefox, but not in safari. In safari it just loads the last image and just sits there doing nothing.

    I decided to put the plugin script into the jquery.js file and I also put the transition code in there which is

    Code javascript:
    $('#slide').cycle({ 
        fx:    'fade', 
        speed:  1000 ,
     
        // duration of slide
        timeout: 5000, 
     });

    my html is

    Code html4strict:
    <div id="slide">
    <img width="928" height="293" src="/drupal/sites/default/files/imagecache/rotate/home/vehicle1.png" alt="" />
    <img width="928" height="293" src="/drupal/sites/default/files/imagecache/rotate/home/vehicle2.png" alt="" />
    <img width="928" height="293" src="/drupal/sites/default/files/imagecache/rotate/home/vehicle3t.png" alt="" />
    </div>

    and my css

    Code css:
    #slide{
    	width:928px;
    	height:293px;
    	padding: 0;  
        margin:  0;
    	}
     
    	#slide img {  
        padding: 0;  
        background-color: #222;  
        width:  928px; 
        height: 293px; 
        top:  0; 
        left: 0;
        position: absolute;
    	}

    On the Cycle plugin page it doesnt say anything about using absolute on the image, but without it my images r all displayed in safari 1 after the other. I doubt it could be because its in the jquery.js file, but I don't know what to do at this point. Can some1 please help me with this?
    Last edited by iii; Aug 13, 2008 at 00:42.

  2. #2
    Unobtrusively zen silver trophybronze trophy
    paul_wilkins's Avatar
    Join Date
    Jan 2007
    Location
    Christchurch, New Zealand
    Posts
    14,678
    Mentioned
    99 Post(s)
    Tagged
    4 Thread(s)
    Works for me.

    I've created a test page using the code you posted, and it works fine in Safari 3.0
    Programming Group Advisor
    Reference: JavaScript, Quirksmode Validate: HTML Validation, JSLint
    Car is to Carpet as Java is to JavaScript

  3. #3
    SitePoint Guru
    Join Date
    Oct 1999
    Location
    New York, NY
    Posts
    826
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hey Fellow SitePoint-ers!

    I'm having some slight difficulty with the jquery cycle plugin so I figured I'd post in this recent thread...

    For the most part, I was able to successfully get the cycle plugin to work but only in FADE mode! That's all fine and good, but I'd love to figure out how to get the other fun transitions on board...

    My test page correctly showing the fade is at http://preview.tinyurl.com/652c6n

    Specifically, I'd love the shuffle option or scrollDown option on this page to work http://malsup.com/jquery/cycle/int.html -- I've adjusted the code in my jqcycle.js to reflect the shuffle etc. but hasn't work... current jqcycle.js code:

    Code:
    $(document).ready(function() {
      $("#bpic").cycle({
        random: 1,
        fx: 'fade',
        timeout: 1000,
        speed: 1000,
      });
    });
    What am I missing?!

    Thanks,
    Josh

  4. #4
    SitePoint Member
    Join Date
    Mar 2009
    Posts
    14
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm having the exact same problem. i put 'absolute' after reading this thread, and my banner is just sitting there doing nothing as well. http://www.werwinning.com
    ::sign::


Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •