[wp-trac] [WordPress Trac] #21676: Pass a variable to get_template_part()
WordPress Trac
noreply at wordpress.org
Thu Jun 4 17:13:01 UTC 2020
#21676: Pass a variable to get_template_part()
-------------------------------------+------------------------------
Reporter: sc0ttkclark | Owner: SergeyBiryukov
Type: enhancement | Status: reviewing
Priority: normal | Milestone: Awaiting Review
Component: Template | Version: 3.4.1
Severity: normal | Resolution:
Keywords: has-patch needs-testing | Focuses:
-------------------------------------+------------------------------
Comment (by joyously):
I agree with the core devs that `get_template_part` should not have
variables passed. Everything needed in a template part should already be
retrievable through functions or you need to be doing something else
entirely. The theme has to be fairly generic to work in all situations.
Custom details belong in plugins.
+100 for close or wontfix
--
Ticket URL: <https://core.trac.wordpress.org/ticket/21676#comment:73>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list