Echo do_shortcode with ACF variable. Is it possible
-
I’m wondering if there is a way to do this?
I’d like the variable of an ACF field to echo the url of a video into the shortcode url.. Is there a specific way to do this? I appreciate any insight.
<?php $video = the_sub_field( ‘video_url’ );?>
<?php echo do_shortcode(‘[su_youtube url=”‘.$video.'” width=”600″ height=”400″ responsive=”yes” autoplay=”no” mute=”no” class=””]’); ?>
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Echo do_shortcode with ACF variable. Is it possible’ is closed to new replies.