PHP Widget and do_shortcode
The problem was the double quotes which are needed in normal shortcode usage in posts and pages for some reason when using do_shortcode the double quotes in the attributes where breaking the function. Working code below <div> <?php $lat = get_field(‘woo_maps_lat’); $long = get_field(‘woo_maps_long’); echo do_shortcode(‘[forecast location=’ . $lat .’,’.$long. ‘]’); ?> </div>