How can I get a variable into a sidebar?
$sidebarnum = 4;
dynamic_sidebar('Footer Widget $sidebarnum'); ?>`
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It only takes a minute to sign up.
Sign up to join this communityHow can I get a variable into a sidebar?
$sidebarnum = 4;
dynamic_sidebar('Footer Widget $sidebarnum'); ?>`
Replace this line
dynamic_sidebar('Footer Widget $sidebarnum');
with this
dynamic_sidebar('Footer Widget ' . $sidebarnum);