-
AuthorPosts
-
June 17, 2020 at 12:39 pm #1223342
Hi there
I would like to limit the autorotation of a series of content sliders to one loop only. I found 2014 instructions at … https://kriesi.at/support/topic/content-slider-loop/ … The code mentioned has moved to slideshow.js and been amended in recent versions of Enfold (am using 4.7.4). Can you tell me how to proceed now?
I was also wondering if you had come across any method that would enable a fullscreen slideshow to pull images at random from an array?
Many thanks
Jane Joyce
June 23, 2020 at 11:01 am #1224808Hey JaneJoyce,
Thank you for the inquiry.
You have to create a new shortcode path in the child theme folder and override the script there.
// https://kriesi.at/documentation/enfold/intro-to-layout-builder/#add-elements-to-alb
This function in the contentslider.php file loads the scripts and stylesheets, so it has to be adjusted.
function extra_assets() { //load css wp_enqueue_style( 'avia-module-slideshow', AviaBuilder::$path['pluginUrlRoot'] . 'avia-shortcodes/slideshow/slideshow.css', array( 'avia-layout' ), false ); wp_enqueue_style( 'avia-module-postslider', AviaBuilder::$path['pluginUrlRoot'] . 'avia-shortcodes/postslider/postslider.css', array( 'avia-layout' ), false ); wp_enqueue_style( 'avia-module-slideshow-contentpartner', AviaBuilder::$path['pluginUrlRoot'] . 'avia-shortcodes/contentslider/contentslider.css', array( 'avia-module-slideshow' ), false ); //load js wp_enqueue_script( 'avia-module-slideshow', AviaBuilder::$path['pluginUrlRoot'] . 'avia-shortcodes/slideshow/slideshow.js', array( 'avia-shortcodes' ), false, true ); }
Make sure that the path in the wp_enqueue_script function points to the script with the modification.
wp_enqueue_script( 'avia-module-slideshow', AviaBuilder::$path['pluginUrlRoot'] . 'avia-shortcodes/slideshow/slideshow.js', array( 'avia-shortcodes' ), false, true );
Best regards,
IsmaelJune 24, 2020 at 12:50 pm #1225164Many thanks Ismael, I appreciate your help. Will implement and see how we go.
You can close the ticket.Jane
June 24, 2020 at 5:01 pm #1225285 -
AuthorPosts
- You must be logged in to reply to this topic.