WordPress.org

Forums

Shortcodes Ultimate
[resolved] Images not showing (nivo & jcarousel) (5 posts)

  1. jennybeaumont
    Member
    Posted 3 years ago #

    Hi!
    Am really excited about this plugin, seems very promising! Having trouble however getting the Nivo slider to work. The formatting comes up (I can see buttons and the links are in place), but the images just don't show. Tried it with the jcarousel as well and have the same prob.

    It seems the background image link is as follows:
    url("http://newwdp.m-2a.fr/wp-content/plugins/shortcodes-ultimate/lib/timthumb.php?src=http://newwdp.m-2a.fr/wp-content/uploads/2012/01/londres_2012.jpg&w=710&h=312&zc=1&q=100") no-repeat scroll 0 0 transparent

    Whereas I think it should simply be
    url("http://newwdp.m-2a.fr/wp-content/uploads/2012/01/londres_2012.jpg") no-repeat scroll 0 0 transparent

    Am I wrong? Can't seem to find where this happens in your code, but will keep digging. Just wanted to put the word out and see if anyone else has experienced this and/or if there might be another reason for it.

    thanks!
    -jennyb

    http://wordpress.org/extend/plugins/shortcodes-ultimate/

  2. jennybeaumont
    Member
    Posted 3 years ago #

    Ok, so I changed lines 54 & 85 in lib/images.php, removing the extra link info that's bogus (at least on my end it causing interference) and it's working.

    cheers!
    -jennyb

  3. Vladimir Anokhin
    Member
    Plugin Author

    Posted 3 years ago #

    Hi, jennybeaumont.

    You just need to change folder permissions through FTP.

    /wp-content/plugins/shortcodes-ultimate/lib/cache/

    change CHMOD of this folder to 777

    How to do this - https://google.com/search?q=how+to+change+chmod+ftp

  4. jennybeaumont
    Member
    Posted 3 years ago #

    OH! I didn't even think of that :)

    Thanks man, awesome plugin!
    -jennyb

  5. df
    Member
    Posted 2 years ago #

    Just a quick update on this one, I found I was having issues with images not displaying in Firefox and IE but they were fine in Chrome. Seems to be the way Chrome dealt with the ampersands in the 'thumbnail' URLs.

    Fixed this without changing any folder permissions, just replaced the following code in my /wp-content/plugins/shortcodes-ultimate/lib/images.php file.

    from line 52...

    $return[] = array(
    	'id' => $attachment->ID,
    	'image' => $attachment->guid,
    	'thumbnail' => su_plugin_url() . '/lib/timthumb.php?src=' . $attachment->guid . '&w=' . $width . '&h=' . $height . '&zc=1&q=100',
    	'link' => $linked,
    	'name' => $attachment->post_title,
    'description' => $attachment->post_content
    );

    ...with the following...

    $relativeurl = str_replace(get_bloginfo('url'), '', $attachment->guid);
    $return[] = array(
    	'id' => $image->ID,
    	'image' => su_get_post_image( $image->ID ),
    	'thumbnail' => su_plugin_url() . '/lib/timthumb.php?src=' . $relativeurl . '&w=' . $width . '&h=' . $height . '&zc=1&q=100',
    	'link' => $linked,
    	'name' => $image->post_title,
    	'description' => $image->post_excerpt
    );

    ...and similar changes from line 84, replacing the following...

    $return[] = array(
    	'id' => $image->ID,
    	'image' => su_get_post_image( $image->ID ),
    	'thumbnail' => su_plugin_url() . '/lib/timthumb.php?src=' . su_get_post_image( $image->ID ) . '&w=' . $width . '&h=' . $height . '&zc=1&q=100',
    	'link' => $linked,
    	'name' => $image->post_title,
    	'description' => $image->post_excerpt
    );

    ...with this...

    $relativeurl = str_replace(get_bloginfo('url'), '', su_get_post_image( $image->ID ));
    $return[] = array(
    	'id' => $image->ID,
    	'image' => su_get_post_image( $image->ID ),
    	'thumbnail' => su_plugin_url() . '/lib/timthumb.php?src=' . $relativeurl . '&w=' . $width . '&h=' . $height . '&zc=1&q=100',
    	'link' => $linked,
    	'name' => $image->post_title,
    	'description' => $image->post_excerpt
    );

    The 'str_replace' converts the absolute URL to a relative one and inside the 'thumbnail' array value uses regular ampersands (&) rather than the HTML code (amp;)

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic