entry.tpl.php
45 lines
| 1 | <?php |
| 2 | /** |
| 3 | * LiteSpeed Cache Dashboard Wrapper |
| 4 | * |
| 5 | * Renders the main dashboard page for the LiteSpeed Cache plugin in the WordPress admin area. |
| 6 | * |
| 7 | * @package LiteSpeed |
| 8 | * @since 1.0.0 |
| 9 | */ |
| 10 | |
| 11 | namespace LiteSpeed; |
| 12 | |
| 13 | defined( 'WPINC' ) || exit; |
| 14 | |
| 15 | $menu_list = array( |
| 16 | 'dashboard' => esc_html__( 'Dashboard', 'litespeed-cache' ), |
| 17 | ); |
| 18 | |
| 19 | if ( $this->_is_network_admin ) { |
| 20 | $menu_list = array( |
| 21 | 'network_dash' => esc_html__( 'Network Dashboard', 'litespeed-cache' ), |
| 22 | ); |
| 23 | } |
| 24 | |
| 25 | ?> |
| 26 | |
| 27 | <div class="wrap"> |
| 28 | <h1 class="litespeed-h1"> |
| 29 | <?php echo esc_html__( 'LiteSpeed Cache Dashboard', 'litespeed-cache' ); ?> |
| 30 | </h1> |
| 31 | <span class="litespeed-desc"> |
| 32 | <?php echo esc_html( 'v' . Core::VER ); ?> |
| 33 | </span> |
| 34 | <hr class="wp-header-end"> |
| 35 | </div> |
| 36 | |
| 37 | <div class="litespeed-wrap"> |
| 38 | <?php |
| 39 | foreach ( $menu_list as $tab_key => $tab_val ) { |
| 40 | echo '<div data-litespeed-layout="' . esc_attr( $tab_key ) . '">'; |
| 41 | require LSCWP_DIR . 'tpl/dash/' . $tab_key . '.tpl.php'; |
| 42 | echo '</div>'; |
| 43 | } |
| 44 | ?> |
| 45 | </div> |