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
← All changes | includes/partials/install-page.php +11 -7 4.5.05.3.5 View file →
@@ -5,22 +5,26 @@
5 5 * @since 2.1
6 6 * @package elasticpress
7 7 */
8 8
9 +use ElasticPress\FeatureRequirementsStatus;
10 +
9 11 if ( ! defined( 'ABSPATH' ) ) {
10 12 exit; // Exit if accessed directly.
11 13 }
12 14
15 +$install_status = \ElasticPress\Installer::factory()->get_install_status();
16 +
13 17 if ( defined( 'EP_IS_NETWORK' ) && EP_IS_NETWORK ) {
14 18 $setup_url = admin_url( 'network/admin.php?page=elasticpress-settings' );
15 - $sync_url = admin_url( 'network/admin.php?page=elasticpress-sync&do_sync' );
16 19 $dashboard_url = admin_url( 'network/admin.php?page=elasticpress' );
17 20 } else {
18 21 $setup_url = admin_url( 'admin.php?page=elasticpress-settings' );
19 - $sync_url = admin_url( 'admin.php?page=elasticpress-sync&do_sync' );
20 22 $dashboard_url = admin_url( 'admin.php?page=elasticpress' );
21 23 }
22 24
25 +$sync_url = \ElasticPress\Utils\get_sync_url( 'install' );
26 +
23 27 $skip_install_url = add_query_arg(
24 28 [
25 29 'ep-skip-install' => 1,
26 30 'ep-skip-features' => 1,
@@ -63,9 +67,9 @@
63 67 <?php esc_html_e( 'Step', 'elasticpress' ); ?><p>2</p>
64 68 </div>
65 69 <h2><?php esc_html_e( 'Set up Elasticsearch hosting', 'elasticpress' ); ?></h2>
66 70 <p class="ep-copy-text">
67 - <?php echo wp_kses_post( __( 'The next step is to make sure you have a working Elasticsearch server. We recommend creating an <a href="https://elasticpress.io">ElasticPress.io</a> account or if you want you can set up your own hosting.', 'elasticpress' ) ); ?>
71 + <?php echo wp_kses_post( __( 'The next step is to make sure you have a working Elasticsearch server. We recommend creating an <a href="https://elasticpress.io" target="_blank">ElasticPress.io</a> account or if you want you can set up your own hosting.', 'elasticpress' ) ); ?>
68 72 </p>
69 73 <?php if ( 2 === $install_status ) : ?>
70 74 <div class="setup-message">
71 75 <a class="setup-button" href="<?php echo esc_url( $setup_url ); ?>"><?php esc_html_e( 'Got hosting? Get Started', 'elasticpress' ); ?></a>
@@ -84,12 +88,12 @@
84 88 <ul class="ep-feature-list">
85 89 <?php
86 90 $features = \ElasticPress\Features::factory()->registered_features;
87 91 foreach ( $features as $feature ) {
88 - $feature_status_code = (int) $feature->requirements_status()->code;
92 + $feature_status_code = (int) $feature->requirements_status()->get_code();
89 93 $activation_available = $feature->available_during_installation;
90 94
91 - if ( 2 === $feature_status_code ) {
95 + if ( in_array( $feature_status_code, [ FeatureRequirementsStatus::FORCE_DISABLED, FeatureRequirementsStatus::TEMPORARILY_DISABLED ], true ) ) {
92 96 continue;
93 97 }
94 98
95 99 if ( ! $activation_available ) {
@@ -95,9 +99,9 @@
95 99 if ( ! $activation_available ) {
96 100 continue;
97 101 }
98 102
99 - $should_be_checked = 0 === $feature_status_code || $feature->is_active();
103 + $should_be_checked = FeatureRequirementsStatus::AUTO_ENABLED === $feature_status_code || $feature->is_active();
100 104 ?>
101 105 <li>
102 106 <label>
103 107 <input
@@ -121,9 +125,9 @@
121 125 ?>
122 126 </span>
123 127 </a>
124 128 <span role="tooltip" class="a11y-tip__help a11y-tip__help--top">
125 - <?php echo esc_html( $feature->summary ); ?>
129 + <?php echo wp_kses( $feature->summary, 'ep-html' ); ?>
126 130 <?php esc_html_e( 'Click to learn more.', 'elasticpress' ); ?>
127 131 </span>
128 132 </span>
129 133 <?php endif; ?>