WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] JJ NextGen JQuery Carousel - problem with variable wrap - shortcode (2 posts)

  1. lamialex
    Member
    Posted 1 year ago #

    Hello,

    First of all, I can't find anywhere how to create the link [Plugin: ....] that appears above the Topic Title of each topic on this forum. I have tried putting that in my Topic Title but it doesn't work the same.

    Anyway, my question is about the plugin JJ NextGen JQuery Carousel.

    I'm using the shortcode in a php file:

    echo do_shortcode( '[jj-ngg-jquery-carousel gallery="17" width="100" height="148" visible="6" scroll="6" auto="0" wrap="null" order="sortorder" gap="24" skin_class="jcarousel-skin-tango"]' );

    I'm not really sure about the variable wrap.
    On the plugin webpage it says:

    wrap: Specifies whether to wrap at the first/last item (or both) and jump back to the start/end. Options are "first", "last", "both" or "circular" as string. If set to null, wrapping is turned off (default). (sc: wrap="setting")

    But set to to null is not very clear. I tried "null", "0", "none", even a random text and it does the same, it doesn't put any wrapping which is what I wanted but the next and previous buttons still appear and they shouldn't. They don't if I use this widget via the WordPress Appearance>Widget page and set wrap to "none". So I guess via this, wrap is set to the correct setting.

    Does anyone have an answer for this?
    Thanks.

  2. lamialex
    Member
    Posted 1 year ago #

    I actually found a solution.
    So here it is for anyone who has the same problem because there is a mistake in that plugin.
    It says that by default wrap is set to null but it is not the case, it is set to circular. I don't know how to set wrap to NULL in the shortcode but if you open the file functions.php in the JJ NextGen JQuery Carousel plugin folder, you need to find the line:

    if(WPJJNGGJ_CAROUSEL_use_default($instance, 'wrap')) { $instance['wrap'] = 'circular'; }

    and change it to:

    if(WPJJNGGJ_CAROUSEL_use_default($instance, 'wrap')) { $instance['wrap'] = NULL; }

    and then remove wrap in the shortcode and it works.

Topic Closed

This topic has been closed to new replies.

About this Topic