How can i put an array as variable in shortcode_atts?

Ok found a solution

function product_gallery_shortcode($atts) {
extract(shortcode_atts(array(
            'product_id' => '31',
            'prodvid' => false,
            'youtubeids'=> '',
            'thumbnr' =>2
                ), $atts));
etc

and i had to turn youtubeids into an array again

$youtubeidsnew = array();
$youtubeidsnew = explode(',', $youtubeids);

Leave a Comment

tech