add wp-rocket
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
/**
|
||||
* Documentation block template.
|
||||
*
|
||||
* @since 3.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
?>
|
||||
|
||||
<div class="wpr-documentation">
|
||||
<i class="wpr-icon-book"></i>
|
||||
<h3 class="wpr-title2"><?php esc_html_e( 'Documentation', 'rocket' ); ?></h3>
|
||||
<p><?php esc_html_e( 'It is a great starting point to fix some of the most common issues.', 'rocket' ); ?></p>
|
||||
|
||||
<?php
|
||||
$this->render_action_button(
|
||||
'link',
|
||||
'documentation',
|
||||
[
|
||||
'label' => __( 'Read the documentation', 'rocket' ),
|
||||
'attributes' => [
|
||||
'target' => '_blank',
|
||||
'class' => 'wpr-button wpr-button--small wpr-button--blueDark',
|
||||
],
|
||||
]
|
||||
);
|
||||
?>
|
||||
|
||||
</div>
|
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
/**
|
||||
* Getting Started block template.
|
||||
*
|
||||
* @since 3.4
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
$rocket_tutorials = [
|
||||
'7seqacq2ol' => __( 'What WP Rocket Does For You By Default', 'rocket' ),
|
||||
'fj42vucf99' => __( 'Finding the Best Settings for Your Site', 'rocket' ),
|
||||
'z1qxl7s2zn' => __( 'How to Check if WP Rocket is Caching Your Site', 'rocket' ),
|
||||
'j042jylrre' => __( 'How to Measure the Speed of Your Site', 'rocket' ),
|
||||
];
|
||||
?>
|
||||
<div class="wpr-optionHeader">
|
||||
<h3 class="wpr-title2"><?php esc_html_e( 'Getting Started', 'rocket' ); ?></h3>
|
||||
</div>
|
||||
<div class="wpr-fieldsContainer-fieldset">
|
||||
<div class="wpr-field">
|
||||
<ul class="wpr-field-list">
|
||||
<?php foreach ( $rocket_tutorials as $rocket_tutorial_id => $rocket_tutorial_title ) : ?>
|
||||
<?php // phpcs:ignore WordPress.WP.EnqueuedResources.NonEnqueuedScript ?>
|
||||
<li class="wpr-icon-tutorial-alt"><script src="https://fast.wistia.com/embed/medias/<?php echo esc_attr( $rocket_tutorial_id ); ?>.jsonp" async></script><span class="wpr-tutorial-link wistia_embed wistia_async_<?php echo esc_attr( $rocket_tutorial_id ); ?> popover=true popoverContent=link" style="display:inline;position:relative"><?php echo esc_html( $rocket_tutorial_title ); ?></span></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
/**
|
||||
* Sidebar template.
|
||||
*
|
||||
* @since 3.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
?>
|
||||
|
||||
<h3 class="wpr-Sidebar-title wpr-title2"><?php esc_html_e( 'How to correctly measure your website’s loading time', 'rocket' ); ?></h3>
|
||||
<div class="wpr-Sidebar-notice">
|
||||
<p><?php esc_html_e( 'Check our tutorial and learn how to measure the speed of your site.', 'rocket' ); ?></p>
|
||||
<?php // phpcs:ignore WordPress.WP.EnqueuedResources.NonEnqueuedScript ?>
|
||||
<script src="https://fast.wistia.com/embed/medias/j042jylrre.jsonp" async></script><img src="<?php echo esc_url( WP_ROCKET_ASSETS_IMG_URL . 'play-alt.svg' ); ?>" width="10" height="10" alt=""> <span class="wpr-tutorial-link wpr-Sidebar-notice-link wistia_embed wistia_async_j042jylrre popover=true popoverContent=link" style="display:inline;position:relative"><?php esc_html_e( 'Watch the video', 'rocket' ); ?></span>
|
||||
</div>
|
||||
<div class="wpr-Sidebar-notice">
|
||||
<p><?php esc_html_e( 'Learn how to use best practices to correctly measure your site\'s performance.', 'rocket' ); ?></p>
|
||||
<a href="<?php echo esc_url( __( 'https://wp-rocket.me/blog/correctly-measure-websites-page-load-time/?utm_source=wp_plugin&utm_medium=wp_rocket', 'rocket' ) ); ?>" target="_blank" class="wpr-Sidebar-notice-link"><?php esc_html_e( 'Read our guide', 'rocket' ); ?></a>
|
||||
</div>
|
||||
<div class="wpr-Sidebar-notice">
|
||||
<p><?php esc_html_e( 'Why Google PageSpeed grade should not matter', 'rocket' ); ?></p>
|
||||
<a href="<?php echo esc_url( __( 'https://wp-rocket.me/blog/the-truth-about-google-pagespeed-insights/?utm_source=wp_plugin&utm_medium=wp_rocket', 'rocket' ) ); ?>" target="_blank" class="wpr-Sidebar-notice-link"><?php esc_html_e( 'Read more', 'rocket' ); ?></a>
|
||||
</div>
|
||||
<?php if ( ! get_rocket_option( 'cache_logged_user', 0 ) ) : ?>
|
||||
<div class="wpr-Sidebar-info">
|
||||
<i class="wpr-icon-information2"></i>
|
||||
<h4><?php esc_html_e( 'You have not activated logged-in user cache.', 'rocket' ); ?></h4>
|
||||
<p><?php esc_html_e( 'Use a private browser to check your website\'s speed and visual appearance.', 'rocket' ); ?></p>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php
|
||||
$this->render_part( 'documentation' );
|
Reference in New Issue
Block a user