Diff: STRATO-apps/wordpress_03/app/wp-content/plugins/wp-rocket/views/settings/page-sections/imagify.php

Keine Baseline-Datei – Diff nur gegen leer.
Zur Liste
1 -
1 + <?php
2 + /**
3 + * Imagify section template.
4 + *
5 + * @since 3.2
6 + */
7 +
8 + defined( 'ABSPATH' ) || exit;
9 +
10 + ?>
11 +
12 + <div id="imagify" class="wpr-Page">
13 + <div class="wpr-sectionHeader">
14 + <h2 class="wpr-title1 wpr-icon-imagify-hover"><?php esc_html_e( 'Image Optimization', 'rocket' ); ?></h2>
15 + </div>
16 + <pre>
17 + </pre>
18 + <div class="wpr-mt-2">
19 + <h4 class="wpr-title2">
20 + <?php
21 + // Translators: %1$s = <strong>, %2$s = </strong>.
22 + printf( esc_html__( '%1$sWP Rocket created IMAGIFY to give your website an extra speed boost!%2$s', 'rocket' ), '<strong>', '</strong>' );
23 + ?>
24 + </h4>
25 + </div>
26 +
27 + <p class="wpr-fs-md">
28 + <?php esc_html_e( 'Images can account for 50% of your loading time!', 'rocket' ); ?>
29 + </p>
30 + <p class="wpr-fs-md">
31 + <?php esc_html_e( 'Imagify automatically optimizes all your images, helping your website gain precious seconds while saving you time. With just one click, it resizes, compresses, and converts your images to WebP and AVIF formats without sacrificing quality.', 'rocket' ); ?>
32 + </p>
33 +
34 + <div class="wpr-imagify">
35 + <div class="wpr-imagify-description">
36 + <ul>
37 + <li class="wpr-imagify-info">
38 + <span class="text">
39 + <?php
40 + // Translators: %1$s = <strong>, %2$s = </strong>.
41 + printf( esc_html__( '%1$sCompress%2$s all your images in one click', 'rocket' ), '<strong>', '</strong>' );
42 + ?>
43 + </span>
44 + </li>
45 + <li class="wpr-imagify-info">
46 + <span class="text">
47 + <?php
48 + // Translators: %1$s = <strong>, %2$s = </strong>.
49 + printf( esc_html__( '%1$sConvert%2$s images to WebP and Avif', 'rocket' ), '<strong>', '</strong>' );
50 + ?>
51 + </span>
52 + </li>
53 + <li class="wpr-imagify-info">
54 + <span class="text">
55 + <?php
56 + // Translators: %1$s = <strong>, %2$s = </strong>.
57 + printf( esc_html__( '%1$sResize%2$s your images on the fly', 'rocket' ), '<strong>', '</strong>' );
58 + ?>
59 + </span>
60 + </li>
61 + <li class="wpr-imagify-info">
62 + <span class="text">
63 + <?php
64 + // Translators: %1$s = <strong>, %2$s = </strong>.
65 + printf( esc_html__( '%1$sFree plan%2$s includes 20MB/month (around 200 images)', 'rocket' ), '<strong>', '</strong>' );
66 + ?>
67 + </span>
68 + </li>
69 + </ul>
70 +
71 + </div>
72 + <div class="wpr-imagify-screenshot">
73 + <img src="<?php echo esc_attr( WP_ROCKET_ASSETS_IMG_URL . 'imagify-score.png' ); ?>" alt="" width="613" height="394">
74 + </div>
75 + </div>
76 + <?php if ( $data ) : ?>
77 + <div class="wpr-imagify-plugin-tile">
78 + <img src="<?php echo esc_url( $data->icons['svg'] ); ?>" alt="Imagify logo" width="65" height="65">
79 + <div class="wpr-imagify-plugin-tile-info">
80 + <h4 class="wpr-imagify-plugin-tile-title">
81 + <?php
82 + // Translators: %1$s = <strong>, %2$s = </strong>.
83 + printf( esc_html__( '%1$sInstall Imagify, the Easiest WordPress Image Optimizer%2$s', 'rocket' ), '<strong>', '</strong>' );
84 + ?>
85 + </h4>
86 + <div class="wpr-star-rating">
87 + <?php
88 + wp_star_rating(
89 + [
90 + 'rating' => ( $data->rating / 100 ) * 5,
91 + 'type' => 'rating',
92 + 'number' => $data->num_ratings,
93 + ]
94 + );
95 + ?>
96 + <div class="num-ratings" aria-hidden="true">(<?php echo esc_html( number_format_i18n( $data->num_ratings ) ); ?>)</div>
97 + </div>
98 + <div class="wpr-fs-sm">
99 + <?php echo esc_html( number_format_i18n( $data->active_installs ) ); ?>+ Active installations
100 + </div>
101 + </div>
102 + <?php
103 + if ( ! \Imagify_Partner::is_imagify_activated() ) {
104 + $imagify = new \Imagify_Partner( 'wp-rocket' ); // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
105 +
106 + if ( \Imagify_Partner::is_imagify_installed() ) {
107 + $button_text = __( 'Activate Imagify', 'rocket' ); // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
108 + $button_icon = 'wpr-icon-chevron-down'; // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
109 + } else {
110 + $button_text = __( 'Install Imagify', 'rocket' ); // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
111 + $button_icon = 'wpr-imagify-install'; // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
112 + }
113 +
114 + echo '<a class="wpr-button ' . esc_attr( $button_icon ) . '" href="' . esc_url( $imagify->get_post_install_url() ) . '">' . esc_html( $button_text ) . '</a>';
115 + }
116 + ?>
117 + </div>
118 + <?php endif; ?>
119 + </div>
120 +