[wp-trac] [WordPress Trac] #21676: Pass a variable to get_template_part()
WordPress Trac
noreply at wordpress.org
Mon Jun 8 09:30:20 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 Mte90):
I agree with @enricosorcinelli, for consistency we need to add this
feature.
It isn't uncommon in WordPress to have functions that support to pass
custom variables or have filter that let to do so.
Considering also that there is a lot of people asking for that
https://www.google.com/search?q=get+template+pass+variable+wordpress
I remember also a composer package that add a similar function just as
replacement for the native one.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/21676#comment:75>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list