• Hi all

    I’m having real problems here so any help would be really appreciated.

    I’m using the jQuery cycle menu here to create a slideshow and thumbnails.

    https://www.ttmt.org.uk/forum/wordpress/

    I want to create the same thing in WordPress

    https://www.ttmt.org.uk/wordpress/

    The slideshow works but thumbnails don’t show.

    I think part of the problem is creating the thumbnails in WordPress so I’m using
    timthumb to create the thumbnails – https://www.binarymoon.co.uk/projects/timthumb/

    I have downloaded timthumb and named the file thumb.php then put it in the folder thumb

    I’m using this to try and create the thumbnails from timthumb.

    <script type="text/javascript">
    
      $(window).load(function() {
         $('#slideshow').cycle({
              fx: 'fade',
              speed: 800,
              timeout: 3000,
              pause:     1,
              next: '#next',
              prev: '#prev',
              pager:  '#thumbs', 
    
              pagerAnchorBuilder: function(idx, slide) {
                return '
    <li><a href="#"><img src="<?php bloginfo('template_directory'); ?>thumb/thumb.php?src="' + slide.src + '"&h=50&w=50&zc=1" /></a></li>
    ';
              } 
    
      });
    
    </script>

    Can anyone see why this isn’t working?

    Will this ever work? Should I stop trying?

Viewing 7 replies - 1 through 7 (of 7 total)
  • check this
    return '<li><a href="#"><img src="<?php bloginfo('template_directory'); ?>thumb/thumb.php?src='+slide.src+'&h=50&w=50&zc=1" /></a></li>';

    Thread Starter ttmt

    (@ttmt)

    thanks for your reply adpawi

    what should I be checking for?

    Can you see something wrong with it.

    Yes. You used twice ” inside url. Before and after slide.src.

    Thread Starter ttmt

    (@ttmt)

    I’m sure the ” are needed to break out of the php statement.

    I took them out and it still doesn’t work.

    No, in this case ‘ break …not “
    ??

    Thread Starter ttmt

    (@ttmt)

    I have tried

    “‘ + slide.src + ‘”

    and

    ‘ + slide.src + ‘

    and

    ” + slide.src + “

    none of them work

    you should check single quote and double quote in (google it)

    return '<li><a href="#"><img src="<?php bloginfo('template_directory'); ?>thumb/thumb.php?src='+slide.src+'&h=50&w=50&zc=1" /></a></li>';

    '<li><a href="#"><img src="<?php bloginfo(' => mean close this string

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Jquery cycle thumbnails with timthumb in WordPress’ is closed to new replies.