PluginProbe
ElasticPress / 5.3.5
ElasticPress v5.3.5
5.3.5 5.3.4 3.6.5 3.6.6 4.0.0 4.0.1 4.1.0 4.2.0 4.2.1 4.2.2 4.3.0 4.3.1 4.4.0 4.4.1 4.5.0 4.5.1 4.5.2 4.6.0 4.6.1 4.7.0 4.7.1 4.7.2 5.0.0 5.0.1 5.0.2 All 108 releases
elasticpress / includes / partials / header.php

header.php in ElasticPress 5.3.5, at includes/partials/header.php

48 lines 2.0 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Header template for ElasticPress settings page
4 *
5 * @since 2.1
6 * @package elasticpress
7 */
8
9 use ElasticPress\Elasticsearch;
10 use ElasticPress\Screen;
11 use ElasticPress\Utils;
12
13 if ( ! defined( 'ABSPATH' ) ) {
14 exit; // Exit if accessed directly.
15 }
16
17 $base_url = ( defined( 'EP_IS_NETWORK' ) && EP_IS_NETWORK ) ? admin_url( 'network/admin.php?page=' ) : admin_url( 'admin.php?page=' );
18 $is_sync_page = 'sync' === Screen::factory()->get_current_screen();
19 ?>
20
21 <div class="ep-header-menu">
22 <a href="<?php echo esc_url( $base_url . 'elasticpress' ); ?>"><img width="150" src="<?php echo esc_url( plugins_url( '/images/logo.svg', dirname( __DIR__ ) ) ); ?>"></a>
23
24 <?php if ( Utils\is_top_level_admin_context() ) : ?>
25 <div class="icons">
26 <span class="sync-status"></span>
27 <?php if ( $is_sync_page ) : ?>
28
29 <a class="dashicons resume-sync dashicons-controls-play" title ="<?php esc_attr_e( 'Resume Sync', 'elasticpress' ); ?>" aria-label="<?php esc_attr_e( 'Resume Sync', 'elasticpress' ); ?>"></a>
30 <a class="dashicons cancel-sync dashicons-no" title="<?php esc_attr_e( 'Cancel Sync', 'elasticpress' ); ?>" aria-label="<?php esc_attr_e( 'Cancel Sync', 'elasticpress' ); ?>"></a>
31 <?php endif; ?>
32 <?php if ( Elasticsearch::factory()->get_elasticsearch_version() && defined( 'EP_DASHBOARD_SYNC' ) && EP_DASHBOARD_SYNC && ! $is_sync_page ) : ?>
33 <a
34 class="dashicons start-sync dashicons-update"
35 title="<?php esc_attr_e( 'Sync Page', 'elasticpress' ); ?>"
36 aria-label="<?php esc_attr_e( 'Sync Page', 'elasticpress' ); ?>"
37 <?php echo ( $is_sync_page ) ? '' : 'href="' . esc_url( $base_url . 'elasticpress-sync' ) . '"'; ?>
38 ></a>
39 <?php endif; ?>
40 <a href="<?php echo esc_url( $base_url . 'elasticpress-settings' ); ?>" class="dashicons dashicons-admin-generic" title="<?php esc_attr_e( 'Settings Page', 'elasticpress' ); ?>" aria-label="<?php esc_attr_e( 'Settings Page', 'elasticpress' ); ?>"></a>
41 </div>
42
43 <div class="progress-bar"></div>
44 <?php endif; ?>
45 </div>
46
47 <hr id="ep-wp-header-end" class="wp-header-end">
48