How to use shortcode in js url June 12, 2022 by Tarik Billa You can not use a shortcode inside an attribute. You need to make a shortcode that will output the whole element.