[wp-meta] [Making WordPress.org] #5759: Support Forums: Improve local environment support
Making WordPress.org
noreply at wordpress.org
Sat May 29 12:48:32 UTC 2021
#5759: Support Forums: Improve local environment support
----------------------------+--------------------
Reporter: Clorith | Owner: (none)
Type: enhancement | Status: new
Priority: normal | Milestone:
Component: Support Forums | Keywords:
----------------------------+--------------------
Currently the foums theme (and many other meta elements really), rely on
the global header and footer fetched via a call to `require WPORGPATH .
'header.php` and `require WPORGPATH . 'footer.php'` respectively.
The global header is not open sourced, so to be able to replicate the
environment locally, one would need to do something like `define(
'WPORGPATH', 'https://wordpress.org/' )` and enable `allow_url_fopen` in
PHP.
This works, but the header is then not aware of any enqueued assets or
other scripts in the local environment that may need to trigger.
The attached patch adds a check if the header or footer actions have been
ran in the support theme after requiring these global files, and will call
`wp_head()` and `wp_footer()` if not.
--
Ticket URL: <https://meta.trac.wordpress.org/ticket/5759>
Making WordPress.org <https://meta.trac.wordpress.org/>
Making WordPress.org
More information about the wp-meta
mailing list