updating documentation
This commit is contained in:
parent
a8e237345b
commit
cee32cee43
|
|
@ -3,20 +3,13 @@
|
||||||
add_action('template_redirect', 'redirect_to_demo_components_page');
|
add_action('template_redirect', 'redirect_to_demo_components_page');
|
||||||
function redirect_to_demo_components_page()
|
function redirect_to_demo_components_page()
|
||||||
{
|
{
|
||||||
if ($_SERVER['REQUEST_URI'] == '/demo-components') {
|
if ($_SERVER['REQUEST_URI'] == '/demo-components' && is_user_logged_in()) {
|
||||||
global $wp_query;
|
global $wp_query;
|
||||||
$wp_query->is_404 = false;
|
$wp_query->is_404 = false;
|
||||||
status_header(200);
|
status_header(200);
|
||||||
include(dirname(__DIR__, 1) . '/demo-components.php');
|
include(dirname(__DIR__, 1) . '/demo-components.php');
|
||||||
exit();
|
exit();
|
||||||
}
|
}
|
||||||
if ($_SERVER['REQUEST_URI'] == '/blocks-status') {
|
|
||||||
global $wp_query;
|
|
||||||
$wp_query->is_404 = false;
|
|
||||||
status_header(200);
|
|
||||||
include(dirname(__DIR__, 1) . '/blocks-status.php');
|
|
||||||
exit();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user