How do I create my own .php file with a code part and echo it on different pages?
There’s a fundamental misunderstanding here about how partials/templates that aren’t full pages/template fragments in WP work. get_* is not how files are loaded, and get_header and get_footer are special cases for legacy reasons, kept for conventions sake. They’re actually equivalent to: get_template_part( ‘header’ ); get_template_part( ‘footer’ ); But with some additional filters and checks so … Read more