WordPress get_template_part pass variable
Using WordPress 5.5+ As of WordPress 5.5, passing variables via get_template_part is part of core. Starting in WordPress 5.5, the template loading functions will now allow additional arguments to be passed through to the matched template file using a new $args parameter. Example: and then in the included file (i.e. template-parts/featured-image), you can either just … Read more