woocommerce/includes/admin/views/html-admin-page-status.php

40 lines
1004 B
PHP
Raw Normal View History

<?php
/**
* Admin View: Page - Status
*/
if ( ! defined( 'ABSPATH' ) ) {
2015-01-20 10:41:26 +00:00
exit;
}
2015-01-20 10:41:26 +00:00
$current_tab = ! empty( $_REQUEST['tab'] ) ? sanitize_title( $_REQUEST['tab'] ) : 'status';
?>
<div class="wrap woocommerce">
<div class="icon32 icon32-woocommerce-status" id="icon-woocommerce"><br /></div><h2 class="nav-tab-wrapper woo-nav-tab-wrapper">
<?php
$tabs = array(
'status' => __( 'System Status', 'woocommerce' ),
'tools' => __( 'Tools', 'woocommerce' ),
'logs' => __( 'Logs', 'woocommerce' ),
);
foreach ( $tabs as $name => $label ) {
2013-10-22 16:26:18 +00:00
echo '<a href="' . admin_url( 'admin.php?page=wc-status&tab=' . $name ) . '" class="nav-tab ';
if ( $current_tab == $name ) echo 'nav-tab-active';
echo '">' . $label . '</a>';
}
?>
2015-04-29 09:47:57 +00:00
</h2>
<?php
switch ( $current_tab ) {
case "tools" :
WC_Admin_Status::status_tools();
break;
case "logs" :
WC_Admin_Status::status_logs();
break;
default :
WC_Admin_Status::status_report();
break;
}
?>
</div>