Plugins and themes.

This commit is contained in:
Greta Thunberg 2023-09-26 10:24:36 +02:00
parent 2a48b254b0
commit 5e05685a51
1784 changed files with 49167 additions and 14912 deletions

View File

@ -12,7 +12,7 @@
</IfModule>
# Akismet CSS and JS
<FilesMatch "^(form\.js|akismet\.js|akismet-frontend\.js|akismet\.css)$">
<FilesMatch "^(form\.js|akismet(-frontend|-admin)?\.js|akismet(-admin)?(-rtl)?\.css|inter\.css)$">
<IfModule !mod_authz_core.c>
Allow from all
</IfModule>
@ -23,7 +23,7 @@
</FilesMatch>
# Akismet images
<FilesMatch "^logo-(a|full)-2x\.png$">
<FilesMatch "^(logo-(a|full)-2x\.png|akismet-refresh-logo\.svg|akismet-refresh-logo@2x\.png|arrow-left\.svg)$">
<IfModule !mod_authz_core.c>
Allow from all
</IfModule>
@ -31,4 +31,4 @@
<IfModule mod_authz_core.c>
Require all granted
</IfModule>
</FilesMatch>
</FilesMatch>

View File

@ -0,0 +1,360 @@
#akismet-plugin-container {
background-color: var(--akismet-color-light-grey);
font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen-Sans', 'Ubuntu', 'Cantarell', 'Helvetica Neue', sans-serif;
--akismet-color-charcoal: #272635;
--akismet-color-light-grey: #f6f7f7;
--akismet-color-mid-grey: #a7aaad;
--akismet-color-dark-grey: #646970;
--akismet-color-grey-80: #2c3338;
--akismet-color-grey-100: #101517;
--akismet-color-white: #fff;
--akismet-color-mid-green: #357b49;
--akismet-color-mid-red: #e82c3f;
--akismet-color-light-blue: #256eff;
--akismet-color-notice-light-green: #dbf0e1;
--akismet-color-notice-dark-green: #69bf82;
--akismet-color-notice-light-red: #ffdbde;
--akismet-color-notice-dark-red: #ff6676;
}
#akismet-plugin-container a {
color: var(--akismet-color-mid-green);
}
#akismet-plugin-container button:focus-visible,
#akismet-plugin-container input:focus-visible {
border: 0;
box-shadow: none;
outline: 2px solid var(--akismet-color-light-blue);
}
.akismet-masthead {
box-shadow: none;
}
.akismet-masthead__logo {
margin: 20px 0;
}
.akismet-section-header {
box-shadow: none;
margin-bottom: 0;
}
.akismet-section-header__label {
color: var(--akismet-color-charcoal);
font-weight: 600;
}
.akismet-button, .akismet-button:hover {
background-color: var(--akismet-color-mid-green);
border: 0;
color: #fff;
}
/* Need this specificity to override the existing header rule */
.akismet-new-snapshot h3.akismet-new-snapshot__header {
background: none;
font-size: 13px;
color: var(--akismet-color-charcoal);
text-align: left;
text-transform: none;
}
.akismet-new-snapshot .akismet-new-snapshot__number {
color: var(--akismet-color-charcoal);
letter-spacing: -1px;
text-align: left;
}
.akismet-new-snapshot li.akismet-new-snapshot__item {
color: var(--akismet-color-dark-grey);
font-size: 13px;
text-align: left;
text-transform: none;
}
.akismet-masthead__logo-link {
min-height: 50px;
}
.akismet-masthead__back-link-container {
margin-top: 16px;
margin-bottom: 2px;
}
/* Need this specificity to override the existing link rule */
#akismet-plugin-container a.akismet-masthead__back-link {
background-image: url(img/arrow-left.svg);
background-position: left;
background-repeat: no-repeat;
background-size: 16px;
color: var(--akismet-color-charcoal);
font-weight: 400;
padding-left: 20px;
text-decoration: none;
}
#akismet-plugin-container a.akismet-masthead__back-link:hover {
text-decoration: underline;
}
.akismet-new-snapshot__item {
border-top: 1px solid var(--akismet-color-light-grey);
border-left: 1px solid var(--akismet-color-light-grey);
padding: 1em;
}
.akismet-new-snapshot li:first-child {
border-left: none;
}
.akismet-new-snapshot__list {
display: flex;
margin-bottom: 0;
}
.akismet-new-snapshot__item {
flex: 1 0 33.33%;
margin-bottom: 0;
padding-left: 1.5em;
padding-right: 1.5em;
}
.akismet-new-snapshot__chart {
padding: 1em;
}
.akismet-box {
border: 0;
}
.akismet-box,
.akismet-card {
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06), 0 0 2px rgba(0, 0, 0, 0.16);
border-radius: 8px;
overflow: hidden;
}
.akismet-card {
margin: 32px auto 0 auto;
}
.akismet-lower {
padding-top: 0;
}
.akismet-lower .inside {
padding: 0;
}
.akismet-section-header__label {
margin: 0;
}
.akismet-settings__row {
border-bottom: 1px solid var(--akismet-color-light-grey);
display: block;
padding: 1em 1.5em;
}
.akismet-settings__row-input {
margin-left: auto;
}
.akismet-settings__row-title {
font-weight: 500;
font-size: 1em;
margin: 0;
margin-bottom: 1em;
}
.akismet-settings__row-description {
margin-top: 0.5em;
}
.akismet-card-actions {
padding: 1em;
}
.akismet-settings__row label {
padding-bottom: 1em;
}
.akismet-settings__row-note {
font-size: 0.9em;
margin-top: 0.4em;
}
.akismet-settings__row input[type="checkbox"],
.akismet-settings__row input[type="radio"] {
accent-color: var(--akismet-color-mid-green);
box-shadow: none;
flex-shrink: 0;
margin: 2px 0 0 0;
}
.akismet-settings__row input[type="checkbox"] {
margin-top: 1px;
vertical-align: top;
-webkit-appearance: checkbox;
}
.akismet-settings__row input[type="radio"] {
-webkit-appearance: radio;
}
/* Fix up misbehaving wp-admin styles in Chrome (from forms and colors stylesheets) */
.akismet-settings__row input[type="checkbox"]:checked:before {
content: '';
}
.akismet-settings__row input[type="radio"]:checked:before {
background: none;
}
.akismet-settings__row input[type="checkbox"]:checked:hover,
.akismet-settings__row input[type="radio"]:checked:hover {
accent-color: var(--akismet-color-mid-green);
}
.akismet-button:disabled {
background-color: var(--akismet-color-mid-grey);
color: var(--akismet-color-white);
cursor: arrow;
}
.akismet-awaiting-stats,
.akismet-account {
padding: 0 1rem 1rem 1rem;
margin: 0;
}
.akismet-account {
padding-bottom: 0;
}
.akismet-account th {
font-weight: 500;
padding-right: 1em;
}
.akismet-account th, .akismet-account td {
padding-bottom: 1em;
}
.akismet-settings__row-input-label {
align-items: center;
display: flex;
}
.akismet-settings__row-label-text {
padding-left: 0.5em;
margin-top: 2px;
}
.akismet-alert {
border-left: 8px solid;
border-radius: 8px;
margin: 20px 0;
padding: 0.2em 1em;
}
.akismet-alert__heading {
font-size: 1em;
}
.akismet-alert.is-good {
background-color: var(--akismet-color-notice-light-green);
border-left-color: var(--akismet-color-notice-dark-green);
}
.akismet-alert.is-neutral {
background-color: var(--akismet-color-white);
border-left-color: var(--akismet-color-dark-grey);
}
.akismet-alert.is-bad {
background-color: var(--akismet-color-notice-light-red);
border-left-color: var(--akismet-color-notice-dark-red);
}
#akismet-plugin-container .akismet-alert.is-good a,
#akismet-plugin-container .akismet-alert.is-bad a {
/* For better contrast - green isn't great */
color: var(--akismet-color-grey-80);
}
/* Setup - API key input */
.akismet-enter-api-key-box {
margin: 1.5rem 0;
}
.akismet-enter-api-key-box__reveal {
background: none;
border: 0;
color: var(--akismet-color-mid-green);
cursor: pointer;
text-decoration: underline;
}
.akismet-enter-api-key-box__form-wrapper {
display: none;
margin-top: 1.5rem;
}
.akismet-enter-api-key-box__input-wrapper {
box-sizing: border-box;
display: flex;
flex-wrap: nowrap;
padding: 0 1.5rem;
width: 100%;
}
.akismet-enter-api-key-box__key-input {
flex-grow: 1;
margin-right: 1rem;
}
h3.akismet-enter-api-key-box__header {
padding-top: 0;
padding-bottom: 1em;
text-align: left;
}
@media screen and (max-width: 782px) {
.akismet-new-snapshot__list {
display: block;
}
.akismet-new-snapshot__number {
float: right;
font-size: 20px;
font-weight: 500;
margin-top: -16px;
}
.akismet-new-snapshot__header {
font-size: 14px;
font-weight: 500;
}
.akismet-new-snapshot__text {
font-size: 12px;
}
.akismet-settings__row input[type="checkbox"],
.akismet-settings__row input[type="radio"] {
height: 24px;
width: 24px;
}
.akismet-settings__row-label-text {
padding-left: 0.8em;
}
.akismet-settings__row input[type="checkbox"],
.akismet-settings__row input[type="radio"] {
margin-top: 0;
}
}

View File

@ -0,0 +1,7 @@
document.addEventListener( 'DOMContentLoaded', function() {
// Prevent aggressive iframe caching in Firefox
var statsIframe = document.getElementById( 'stats-iframe' );
if ( statsIframe ) {
statsIframe.contentWindow.location.href = statsIframe.src;
}
} );

View File

@ -99,46 +99,9 @@ table.comments td.comment p a:after {
font-size: 120%;
margin-top: .5rem;
}
.akismet-alert {
padding: 0.4em 1em 1.4em 1em;
box-sizing: border-box;
box-shadow: 0 0 0 1px rgba(200, 215, 225, 0.5), 0 1px 2px #e9eff3;
}
.akismet-alert h3.akismet-key-status {
color: #fff;
margin: 1em 0 0.5em 0;
}
.akismet-alert.akismet-critical {
background-color: #993300;
}
.akismet-alert.akismet-active {
background-color: #649316;
}
.akismet-alert p.akismet-key-status {
font-size: 24px;
}
.akismet-alert p.akismet-description {
color:#fff;
font-size: 14px;
margin: 0 0;
font-style: normal;
}
.akismet-alert p.akismet-description a,
.akismet-alert p.akismet-description a,
.akismet-alert p.akismet-description a,
.akismet-alert p.akismet-description a {
color: #fff;
}
.akismet-new-snapshot {
margin-top: 1em;
padding: 1em;
text-align: center;
background: #fff;
}
@ -148,34 +111,19 @@ table.comments td.comment p a:after {
color: #888;
font-size: 11px;
margin: 0;
padding: 3px;
}
.new-snapspot ul {
font-size: 12px;
width: 100%;
}
.akismet-new-snapshot ul li {
color: #999;
float: left;
font-size: 11px;
padding: 0 20px;
text-transform: uppercase;
width: 33%;
box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
-ms-box-sizing: border-box;
}
.akismet-new-snapshot ul li:first-child,
.akismet-new-snapshot ul li:nth-child(2) {
border-right:1px dotted #ccc;
}
.akismet-new-snapshot ul li span {
color: #52accc;
.akismet-new-snapshot__number {
display: block;
font-size: 32px;
font-weight: lighter;
@ -192,10 +140,6 @@ table.comments td.comment p a:after {
padding-top: 0;
}
.akismet-settings input[type=text] {
width: 75%;
}
.akismet-settings span.akismet-note{
float: left;
padding-left: 23px;
@ -312,7 +256,7 @@ table.comments td.comment p a:after {
.akismet_activate .aa_a {
display: none;
}
.akismet_activate .aa_button_container {
width: 100%;
}
@ -328,7 +272,7 @@ table.comments td.comment p a:after {
#akismet_setup_prompt .aa_description {
display: none;
}
.akismet_activate {
min-width: 0;
}
@ -359,10 +303,6 @@ table.comments td.comment p a:after {
.akismet-masthead__logo-container {
padding:.3125rem 0 0
}
.akismet-masthead__logo {
width:10.375rem;
height:1.8125rem;
}
.akismet-masthead__logo-link {
display:inline-block;
outline:none;
@ -448,10 +388,8 @@ table.comments td.comment p a:after {
margin-top: 1rem;
margin-bottom: 0;
position: relative;
margin: 0 auto 0.625rem auto;
box-sizing: border-box;
background: white;
box-shadow: 0 0 0 1px rgba(200, 215, 225, 0.5), 0 1px 2px #e9eff3;
}
.akismet-card:after, .akismet-card .inside:after, .akismet-masthead__logo-container:after {
@ -507,7 +445,7 @@ table.comments td.comment p a:after {
width: 54px;
height: 54px;
}
.akismet-box p:after {
content: ".";
display: block;
@ -551,15 +489,6 @@ table.comments td.comment p a:after {
text-align: center;
}
.akismet-enter-api-key-box {
margin: 1.5rem 0;
}
.akismet-box .enter-api-key {
display: none;
margin-top: 1.5rem;
}
.akismet-box .akismet-toggles {
margin: 3rem 0;
}
@ -568,10 +497,6 @@ table.comments td.comment p a:after {
display: none;
}
.akismet-box .enter-api-key p {
padding: 0 1.5rem;
}
.akismet-button, .akismet-button:hover, .akismet-button:visited {
background: white;
border-color: #c8d7e1;
@ -699,9 +624,14 @@ div.error.akismet-usage-limit-alert {
}
.akismet-usage-limit-alert .akismet-usage-limit-cta {
border-color: none;
text-align: right;
}
#akismet-plugin-container .akismet-usage-limit-cta a {
color: #d63638;
}
@media (max-width: 550px) {
div.error.akismet-usage-limit-alert {
display: block;

View File

@ -385,10 +385,10 @@ jQuery( function ( $ ) {
/**
* Shows the Enter API key form
*/
$( '.akismet-enter-api-key-box a' ).on( 'click', function ( e ) {
$( '.akismet-enter-api-key-box__reveal' ).on( 'click', function ( e ) {
e.preventDefault();
var div = $( '.enter-api-key' );
var div = $( '.akismet-enter-api-key-box__form-wrapper' );
div.show( 500 );
div.find( 'input[name=key]' ).focus();

View File

@ -0,0 +1,67 @@
@font-face {
font-family: 'Inter';
font-style: normal;
font-weight: 400;
font-display: swap;
src: url("https://s0.wp.com/i/fonts/inter/Inter-Regular.woff2?v=3.19") format("woff2"),
url("https://s0.wp.com/i/fonts/inter/Inter-Regular.woff?v=3.19") format("woff");
}
@font-face {
font-family: 'Inter';
font-style: italic;
font-weight: 400;
font-display: swap;
src: url("https://s0.wp.com/i/fonts/inter/Inter-Italic.woff2?v=3.19") format("woff2"),
url("https://s0.wp.com/i/fonts/inter/Inter-Italic.woff?v=3.19") format("woff");
}
@font-face {
font-family: 'Inter';
font-style: normal;
font-weight: 500;
font-display: swap;
src: url("https://s0.wp.com/i/fonts/inter/Inter-Medium.woff2?v=3.19") format("woff2"),
url("https://s0.wp.com/i/fonts/inter/Inter-Medium.woff?v=3.19") format("woff");
}
@font-face {
font-family: 'Inter';
font-style: italic;
font-weight: 500;
font-display: swap;
src: url("https://s0.wp.com/i/fonts/inter/Inter-MediumItalic.woff2?v=3.19") format("woff2"),
url("https://s0.wp.com/i/fonts/inter/Inter-MediumItalic.woff?v=3.19") format("woff");
}
@font-face {
font-family: 'Inter';
font-style: normal;
font-weight: 600;
font-display: swap;
src: url("https://s0.wp.com/i/fonts/inter/Inter-SemiBold.woff2?v=3.19") format("woff2"),
url("https://s0.wp.com/i/fonts/inter/Inter-SemiBold.woff?v=3.19") format("woff");
}
@font-face {
font-family: 'Inter';
font-style: italic;
font-weight: 600;
font-display: swap;
src: url("https://s0.wp.com/i/fonts/inter/Inter-SemiBoldItalic.woff2?v=3.19") format("woff2"),
url("https://s0.wp.com/i/fonts/inter/Inter-SemiBoldItalic.woff?v=3.19") format("woff");
}
@font-face {
font-family: 'Inter';
font-style: normal;
font-weight: 700;
font-display: swap;
src: url("https://s0.wp.com/i/fonts/inter/Inter-Bold.woff2?v=3.19") format("woff2"),
url("https://s0.wp.com/i/fonts/inter/Inter-Bold.woff?v=3.19") format("woff");
}
@font-face {
font-family: 'Inter';
font-style: italic;
font-weight: 700;
font-display: swap;
src: url("https://s0.wp.com/i/fonts/inter/Inter-BoldItalic.woff2?v=3.19") format("woff2"),
url("https://s0.wp.com/i/fonts/inter/Inter-BoldItalic.woff?v=3.19") format("woff");
}

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 8.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

View File

@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" aria-hidden="true" focusable="false"><path d="M20 11.2H6.8l3.7-3.7-1-1L3.9 12l5.6 5.5 1-1-3.7-3.7H20z"></path></svg>

After

Width:  |  Height:  |  Size: 199 B

View File

@ -0,0 +1,362 @@
/* This file was automatically generated on Aug 25 2023 04:22:56 */
#akismet-plugin-container {
background-color: var(--akismet-color-light-grey);
font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen-Sans', 'Ubuntu', 'Cantarell', 'Helvetica Neue', sans-serif;
--akismet-color-charcoal: #272635;
--akismet-color-light-grey: #f6f7f7;
--akismet-color-mid-grey: #a7aaad;
--akismet-color-dark-grey: #646970;
--akismet-color-grey-80: #2c3338;
--akismet-color-grey-100: #101517;
--akismet-color-white: #fff;
--akismet-color-mid-green: #357b49;
--akismet-color-mid-red: #e82c3f;
--akismet-color-light-blue: #256eff;
--akismet-color-notice-light-green: #dbf0e1;
--akismet-color-notice-dark-green: #69bf82;
--akismet-color-notice-light-red: #ffdbde;
--akismet-color-notice-dark-red: #ff6676;
}
#akismet-plugin-container a {
color: var(--akismet-color-mid-green);
}
#akismet-plugin-container button:focus-visible,
#akismet-plugin-container input:focus-visible {
border: 0;
box-shadow: none;
outline: 2px solid var(--akismet-color-light-blue);
}
.akismet-masthead {
box-shadow: none;
}
.akismet-masthead__logo {
margin: 20px 0;
}
.akismet-section-header {
box-shadow: none;
margin-bottom: 0;
}
.akismet-section-header__label {
color: var(--akismet-color-charcoal);
font-weight: 600;
}
.akismet-button, .akismet-button:hover {
background-color: var(--akismet-color-mid-green);
border: 0;
color: #fff;
}
/* Need this specificity to override the existing header rule */
.akismet-new-snapshot h3.akismet-new-snapshot__header {
background: none;
font-size: 13px;
color: var(--akismet-color-charcoal);
text-align: right;
text-transform: none;
}
.akismet-new-snapshot .akismet-new-snapshot__number {
color: var(--akismet-color-charcoal);
letter-spacing: -1px;
text-align: right;
}
.akismet-new-snapshot li.akismet-new-snapshot__item {
color: var(--akismet-color-dark-grey);
font-size: 13px;
text-align: right;
text-transform: none;
}
.akismet-masthead__logo-link {
min-height: 50px;
}
.akismet-masthead__back-link-container {
margin-top: 16px;
margin-bottom: 2px;
}
/* Need this specificity to override the existing link rule */
#akismet-plugin-container a.akismet-masthead__back-link {
background-image: url(../img/arrow-left.svg);
background-position: right;
background-repeat: no-repeat;
background-size: 16px;
color: var(--akismet-color-charcoal);
font-weight: 400;
padding-right: 20px;
text-decoration: none;
}
#akismet-plugin-container a.akismet-masthead__back-link:hover {
text-decoration: underline;
}
.akismet-new-snapshot__item {
border-top: 1px solid var(--akismet-color-light-grey);
border-right: 1px solid var(--akismet-color-light-grey);
padding: 1em;
}
.akismet-new-snapshot li:first-child {
border-right: none;
}
.akismet-new-snapshot__list {
display: flex;
margin-bottom: 0;
}
.akismet-new-snapshot__item {
flex: 1 0 33.33%;
margin-bottom: 0;
padding-right: 1.5em;
padding-left: 1.5em;
}
.akismet-new-snapshot__chart {
padding: 1em;
}
.akismet-box {
border: 0;
}
.akismet-box,
.akismet-card {
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06), 0 0 2px rgba(0, 0, 0, 0.16);
border-radius: 8px;
overflow: hidden;
}
.akismet-card {
margin: 32px auto 0 auto;
}
.akismet-lower {
padding-top: 0;
}
.akismet-lower .inside {
padding: 0;
}
.akismet-section-header__label {
margin: 0;
}
.akismet-settings__row {
border-bottom: 1px solid var(--akismet-color-light-grey);
display: block;
padding: 1em 1.5em;
}
.akismet-settings__row-input {
margin-right: auto;
}
.akismet-settings__row-title {
font-weight: 500;
font-size: 1em;
margin: 0;
margin-bottom: 1em;
}
.akismet-settings__row-description {
margin-top: 0.5em;
}
.akismet-card-actions {
padding: 1em;
}
.akismet-settings__row label {
padding-bottom: 1em;
}
.akismet-settings__row-note {
font-size: 0.9em;
margin-top: 0.4em;
}
.akismet-settings__row input[type="checkbox"],
.akismet-settings__row input[type="radio"] {
accent-color: var(--akismet-color-mid-green);
box-shadow: none;
flex-shrink: 0;
margin: 2px 0 0 0;
}
.akismet-settings__row input[type="checkbox"] {
margin-top: 1px;
vertical-align: top;
-webkit-appearance: checkbox;
}
.akismet-settings__row input[type="radio"] {
-webkit-appearance: radio;
}
/* Fix up misbehaving wp-admin styles in Chrome (from forms and colors stylesheets) */
.akismet-settings__row input[type="checkbox"]:checked:before {
content: '';
}
.akismet-settings__row input[type="radio"]:checked:before {
background: none;
}
.akismet-settings__row input[type="checkbox"]:checked:hover,
.akismet-settings__row input[type="radio"]:checked:hover {
accent-color: var(--akismet-color-mid-green);
}
.akismet-button:disabled {
background-color: var(--akismet-color-mid-grey);
color: var(--akismet-color-white);
cursor: arrow;
}
.akismet-awaiting-stats,
.akismet-account {
padding: 0 1rem 1rem 1rem;
margin: 0;
}
.akismet-account {
padding-bottom: 0;
}
.akismet-account th {
font-weight: 500;
padding-left: 1em;
}
.akismet-account th, .akismet-account td {
padding-bottom: 1em;
}
.akismet-settings__row-input-label {
align-items: center;
display: flex;
}
.akismet-settings__row-label-text {
padding-right: 0.5em;
margin-top: 2px;
}
.akismet-alert {
border-right: 8px solid;
border-radius: 8px;
margin: 20px 0;
padding: 0.2em 1em;
}
.akismet-alert__heading {
font-size: 1em;
}
.akismet-alert.is-good {
background-color: var(--akismet-color-notice-light-green);
border-right-color: var(--akismet-color-notice-dark-green);
}
.akismet-alert.is-neutral {
background-color: var(--akismet-color-white);
border-right-color: var(--akismet-color-dark-grey);
}
.akismet-alert.is-bad {
background-color: var(--akismet-color-notice-light-red);
border-right-color: var(--akismet-color-notice-dark-red);
}
#akismet-plugin-container .akismet-alert.is-good a,
#akismet-plugin-container .akismet-alert.is-bad a {
/* For better contrast - green isn't great */
color: var(--akismet-color-grey-80);
}
/* Setup - API key input */
.akismet-enter-api-key-box {
margin: 1.5rem 0;
}
.akismet-enter-api-key-box__reveal {
background: none;
border: 0;
color: var(--akismet-color-mid-green);
cursor: pointer;
text-decoration: underline;
}
.akismet-enter-api-key-box__form-wrapper {
display: none;
margin-top: 1.5rem;
}
.akismet-enter-api-key-box__input-wrapper {
box-sizing: border-box;
display: flex;
flex-wrap: nowrap;
padding: 0 1.5rem;
width: 100%;
}
.akismet-enter-api-key-box__key-input {
flex-grow: 1;
margin-left: 1rem;
}
h3.akismet-enter-api-key-box__header {
padding-top: 0;
padding-bottom: 1em;
text-align: right;
}
@media screen and (max-width: 782px) {
.akismet-new-snapshot__list {
display: block;
}
.akismet-new-snapshot__number {
float: left;
font-size: 20px;
font-weight: 500;
margin-top: -16px;
}
.akismet-new-snapshot__header {
font-size: 14px;
font-weight: 500;
}
.akismet-new-snapshot__text {
font-size: 12px;
}
.akismet-settings__row input[type="checkbox"],
.akismet-settings__row input[type="radio"] {
height: 24px;
width: 24px;
}
.akismet-settings__row-label-text {
padding-right: 0.8em;
}
.akismet-settings__row input[type="checkbox"],
.akismet-settings__row input[type="radio"] {
margin-top: 0;
}
}

View File

@ -0,0 +1,649 @@
/* This file was automatically generated on Aug 25 2023 03:41:43 */
.wp-admin.jetpack_page_akismet-key-config, .wp-admin.settings_page_akismet-key-config {
background-color:#f3f6f8;
}
#submitted-on {
position: relative;
}
#the-comment-list .author .akismet-user-comment-count {
display: inline;
}
#the-comment-list .author a span {
text-decoration: none;
color: #999;
}
#the-comment-list .author a span.akismet-span-link {
text-decoration: inherit;
color: inherit;
}
#the-comment-list .akismet_remove_url {
margin-right: 3px;
color: #999;
padding: 2px 0 2px 3px;
}
#the-comment-list .akismet_remove_url:hover {
color: #A7301F;
font-weight: bold;
padding: 2px 0 2px 2px;
}
#dashboard_recent_comments .akismet-status {
display: none;
}
.akismet-status {
float: left;
}
.akismet-status a {
color: #AAA;
font-style: italic;
}
table.comments td.comment p a {
text-decoration: underline;
}
table.comments td.comment p a:after {
content: attr(href);
color: #aaa;
display: inline-block; /* Show the URL without the link's underline extending under it. */
padding: 0 1ex; /* Because it's inline block, we can't just use spaces in the content: attribute to separate it from the link text. */
}
.mshot-arrow {
width: 0;
height: 0;
border-top: 10px solid transparent;
border-bottom: 10px solid transparent;
border-left: 10px solid #5C5C5C;
position: absolute;
right: -6px;
top: 91px;
}
.mshot-container {
background: #5C5C5C;
position: absolute;
top: -94px;
padding: 7px;
width: 450px;
height: 338px;
z-index: 20000;
-moz-border-radius: 6px;
border-radius: 6px;
-webkit-border-radius: 6px;
}
.akismet-mshot {
position: absolute;
z-index: 100;
}
.akismet-mshot .mshot-image {
margin: 0;
height: 338px;
width: 450px;
}
.checkforspam {
display: inline-block !important;
}
.checkforspam-spinner {
display: inline-block;
margin-top: 7px;
}
.akismet-right {
float: left;
}
.akismet-card .akismet-right {
margin: 1em 0;
}
.akismet-alert-text {
color: #dd3d36;
font-weight: bold;
font-size: 120%;
margin-top: .5rem;
}
.akismet-new-snapshot {
margin-top: 1em;
text-align: center;
background: #fff;
}
.akismet-new-snapshot h3 {
background: #f5f5f5;
color: #888;
font-size: 11px;
margin: 0;
}
.akismet-new-snapshot ul li {
color: #999;
font-size: 11px;
text-transform: uppercase;
box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
-ms-box-sizing: border-box;
}
.akismet-new-snapshot__number {
display: block;
font-size: 32px;
font-weight: lighter;
line-height: 1.5em;
}
.akismet-settings th:first-child {
vertical-align: top;
padding-top: 15px;
}
.akismet-settings th.akismet-api-key {
vertical-align: middle;
padding-top: 0;
}
.akismet-settings span.akismet-note{
float: right;
padding-right: 23px;
font-size: 75%;
margin-top: -10px;
}
/**
* For the activation notice on the plugins page.
*/
#akismet_setup_prompt {
background: none;
border: none;
margin: 0;
padding: 0;
width: 100%;
}
.akismet_activate {
border: 1px solid #4F800D;
padding: 5px;
margin: 15px 0;
background: #83AF24;
background-image: -webkit-gradient(linear, 0% 0, 80% 100%, from(#83AF24), to(#4F800D));
background-image: -moz-linear-gradient(-80% 100% 120deg, #4F800D, #83AF24);
-moz-border-radius: 3px;
border-radius: 3px;
-webkit-border-radius: 3px;
position: relative;
overflow: hidden;
}
.akismet_activate .aa_a {
position: absolute;
top: -5px;
left: 10px;
font-size: 140px;
color: #769F33;
font-family: Georgia, "Times New Roman", Times, serif;
}
.akismet_activate .aa_button {
font-weight: bold;
border: 1px solid #029DD6;
border-top: 1px solid #06B9FD;
font-size: 15px;
text-align: center;
padding: 9px 0 8px 0;
color: #FFF;
background: #029DD6;
background-image: -webkit-gradient(linear, 0% 0, 0% 100%, from(#029DD6), to(#0079B1));
background-image: -moz-linear-gradient(0% 100% 90deg, #0079B1, #029DD6);
-moz-border-radius: 2px;
border-radius: 2px;
-webkit-border-radius: 2px;
width: 100%;
cursor: pointer;
margin: 0;
}
.akismet_activate .aa_button:hover {
text-decoration: none !important;
border: 1px solid #029DD6;
border-bottom: 1px solid #00A8EF;
font-size: 15px;
text-align: center;
padding: 9px 0 8px 0;
color: #F0F8FB;
background: #0079B1;
background-image: -webkit-gradient(linear, 0% 0, 0% 100%, from(#0079B1), to(#0092BF));
background-image: -moz-linear-gradient(0% 100% 90deg, #0092BF, #0079B1);
-moz-border-radius: 2px;
border-radius: 2px;
-webkit-border-radius: 2px;
}
.akismet_activate .aa_button_border {
border: 1px solid #006699;
-moz-border-radius: 2px;
border-radius: 2px;
-webkit-border-radius: 2px;
background: #029DD6;
background-image: -webkit-gradient(linear, 0% 0, 0% 100%, from(#029DD6), to(#0079B1));
background-image: -moz-linear-gradient(0% 100% 90deg, #0079B1, #029DD6);
}
.akismet_activate .aa_button_container {
box-sizing: border-box;
display: inline-block;
background: #DEF1B8;
padding: 5px;
-moz-border-radius: 2px;
border-radius: 2px;
-webkit-border-radius: 2px;
width: 266px;
}
.akismet_activate .aa_description {
position: absolute;
top: 22px;
right: 285px;
margin-right: 25px;
color: #E5F2B1;
font-size: 15px;
}
.akismet_activate .aa_description strong {
color: #FFF;
font-weight: normal;
}
@media (max-width: 550px) {
.akismet_activate .aa_a {
display: none;
}
.akismet_activate .aa_button_container {
width: 100%;
}
}
@media (max-width: 782px) {
.akismet_activate {
min-width: 0;
}
}
@media (max-width: 850px) {
#akismet_setup_prompt .aa_description {
display: none;
}
.akismet_activate {
min-width: 0;
}
}
.jetpack_page_akismet-key-config #wpcontent, .settings_page_akismet-key-config #wpcontent {
padding-right: 0;
}
.akismet-masthead {
background-color:#fff;
text-align:center;
box-shadow:0 1px 0 rgba(200,215,225,0.5),0 1px 2px #e9eff3
}
@media (max-width: 45rem) {
.akismet-masthead {
padding:0 1.25rem
}
}
.akismet-masthead__inside-container {
padding:.375rem 0;
margin:0 auto;
width:100%;
max-width:45rem;
text-align: right;
}
.akismet-masthead__logo-container {
padding:.3125rem 0 0
}
.akismet-masthead__logo-link {
display:inline-block;
outline:none;
vertical-align:middle
}
.akismet-masthead__logo-link:focus {
line-height:0;
box-shadow:0 0 0 2px #78dcfa
}
.akismet-masthead__logo-link+code {
margin:0 10px;
padding:5px 9px;
border-radius:2px;
background:#e6ecf1;
color:#647a88
}
.akismet-masthead__links {
display:-ms-flexbox;
display:flex;
-ms-flex-flow:row wrap;
flex-flow:row wrap;
-ms-flex:2 50%;
flex:2 50%;
-ms-flex-pack:end;
justify-content:flex-end;
margin:0
}
@media (max-width: 480px) {
.akismet-masthead__links {
padding-left:.625rem
}
}
.akismet-masthead__link-li {
margin:0;
padding:0
}
.akismet-masthead__link {
font-style:normal;
color:#0087be;
padding:.625rem;
display:inline-block
}
.akismet-masthead__link:visited {
color:#0087be
}
.akismet-masthead__link:active,.akismet-masthead__link:hover {
color:#00aadc
}
.akismet-masthead__link:hover {
text-decoration:underline
}
.akismet-masthead__link .dashicons {
display:none
}
@media (max-width: 480px) {
.akismet-masthead__link:hover,.akismet-masthead__link:active {
text-decoration:none
}
.akismet-masthead__link .dashicons {
display:block;
font-size:1.75rem
}
.akismet-masthead__link span+span {
display:none
}
}
.akismet-masthead__link-li:last-of-type .akismet-masthead__link {
padding-left:0
}
.akismet-lower {
margin: 0 auto;
text-align: right;
max-width: 45rem;
padding: 1.5rem;
}
.akismet-lower .notice {
margin-bottom: 2rem;
}
.akismet-card {
margin-top: 1rem;
margin-bottom: 0;
position: relative;
box-sizing: border-box;
background: white;
}
.akismet-card:after, .akismet-card .inside:after, .akismet-masthead__logo-container:after {
content: ".";
display: block;
height: 0;
clear: both;
visibility: hidden;
}
.akismet-card .inside {
padding: 1.5rem;
padding-top: 1rem;
}
.akismet-card .akismet-card-actions {
margin-top: 1rem;
}
.jetpack_page_akismet-key-config .update-nag, .settings_page_akismet-key-config .update-nag {
display: none;
}
.akismet-masthead .akismet-right {
line-height: 2.125rem;
font-size: 0.9rem;
}
.akismet-box {
box-sizing: border-box;
background: white;
border: 1px solid rgba(200, 215, 225, 0.5);
}
.akismet-box h2, .akismet-box h3 {
padding: 1.5rem 1.5rem .5rem 1.5rem;
margin: 0;
}
.akismet-box p {
padding: 0 1.5rem 1.5rem 1.5rem;
margin: 0;
}
.akismet-jetpack-email {
font-style: oblique;
}
.akismet-jetpack-gravatar {
padding: 0 1.5rem 0 0;
float: right;
margin-left: 1rem;
width: 54px;
height: 54px;
}
.akismet-box p:after {
content: ".";
display: block;
height: 0;
clear: both;
visibility: hidden;
}
.akismet-box .akismet-right {
padding-left: 1.5rem;
}
.akismet-boxes .akismet-box {
margin-bottom: 0;
padding: 0;
margin-top: -1px;
}
.akismet-boxes .akismet-box:last-child {
margin-bottom: 1.5rem;
}
.akismet-boxes .akismet-box:first-child {
margin-top: 1.5rem;
}
.akismet-box-header {
max-width: 700px;
margin: 0 auto 40px auto;
line-height: 1.5;
}
.akismet-box-header h2 {
margin: 1.5rem 10% 0;
font-size: 1.375rem;
font-weight: 700;
color: #000;
}
.akismet-box .centered {
text-align: center;
}
.akismet-box .akismet-toggles {
margin: 3rem 0;
}
.akismet-box .akismet-ak-connect, .akismet-box .toggle-jp-connect {
display: none;
}
.akismet-button, .akismet-button:hover, .akismet-button:visited {
background: white;
border-color: #c8d7e1;
border-style: solid;
border-width: 1px 1px 2px;
color: #2e4453;
cursor: pointer;
display: inline-block;
margin: 0;
outline: 0;
overflow: hidden;
font-size: 14px;
font-weight: 500;
text-overflow: ellipsis;
text-decoration: none;
vertical-align: top;
box-sizing: border-box;
font-size: 14px;
line-height: 21px;
border-radius: 4px;
padding: 7px 14px 9px;
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
}
.akismet-button:hover {
border-color: #a8bece;
}
.akismet-button:active {
border-width: 2px 1px 1px;
}
.akismet-is-primary, .akismet-is-primary:hover, .akismet-is-primary:visited {
background: #00aadc;
border-color: #0087be;
color: white;
}
.akismet-is-primary:hover, .akismet-is-primary:focus {
border-color: #005082;
}
.akismet-is-primary:hover {
border-color: #005082;
}
.akismet-section-header {
position: relative;
margin: 0 auto 0.625rem auto;
padding: 1rem;
box-sizing: border-box;
box-shadow: 0 0 0 1px rgba(200, 215, 225, 0.5), 0 1px 2px #e9eff3;
background: #ffffff;
width: 100%;
padding-top: 0.6875rem;
padding-bottom: 0.6875rem;
display: flex;
}
.akismet-section-header__label {
display: -ms-flexbox;
display: flex;
-ms-flex-align: center;
align-items: center;
-ms-flex-positive: 1;
flex-grow: 1;
line-height: 1.75rem;
position: relative;
font-size: 0.875rem;
color: #4f748e;
}
.akismet-section-header__actions {
line-height: 1.75rem;
}
.akismet-setup-instructions {
text-align: center;
}
.akismet-setup-instructions form {
padding-bottom: 1.5rem;
}
div.error.akismet-usage-limit-alert {
padding: 25px 15px 25px 45px;
display: flex;
align-items: center;
}
#akismet-plugin-container .akismet-usage-limit-alert {
margin: 0 auto 0.625rem auto;
box-sizing: border-box;
box-shadow: 0 0 0 1px rgba(200, 215, 225, 0.5), 0 1px 2px #e9eff3;
border: none;
border-right: 4px solid #d63638;
}
.akismet-usage-limit-alert .akismet-usage-limit-logo {
width: 38px;
min-width: 38px;
height: 38px;
border-radius: 20px;
margin-left: 18px;
background: black;
position: relative;
}
.akismet-usage-limit-alert .akismet-usage-limit-logo img {
position: absolute;
width: 22px;
right: 8px;
top: 10px;
}
.akismet-usage-limit-alert .akismet-usage-limit-text {
flex-grow: 1;
margin-left: 18px;
}
.akismet-usage-limit-alert h3 {
margin: 0;
}
.akismet-usage-limit-alert .akismet-usage-limit-cta {
text-align: left;
}
#akismet-plugin-container .akismet-usage-limit-cta a {
color: #d63638;
}
@media (max-width: 550px) {
div.error.akismet-usage-limit-alert {
display: block;
}
.akismet-usage-limit-alert .akismet-usage-limit-logo,
.akismet-usage-limit-alert .akismet-usage-limit-text {
margin-bottom: 15px;
}
.akismet-usage-limit-alert .akismet-usage-limit-cta {
text-align: right;
}
}

View File

@ -3,13 +3,13 @@
* @package Akismet
*/
/*
Plugin Name: Akismet Anti-Spam: Spam Protection
Plugin Name: Akismet Anti-spam: Spam Protection
Plugin URI: https://akismet.com/
Description: Used by millions, Akismet is quite possibly the best way in the world to <strong>protect your blog from spam</strong>. Akismet anti spam keeps your site protected even while you sleep. To get started: activate the Akismet plugin and then go to your Akismet Settings page to set up your API key.
Version: 5.1
Requires at least: 5.0
Requires PHP: 5.2
Author: Automattic - Anti Spam Team
Description: Used by millions, Akismet is quite possibly the best way in the world to <strong>protect your blog from spam</strong>. Akismet Anti-spam keeps your site protected even while you sleep. To get started: activate the Akismet plugin and then go to your Akismet Settings page to set up your API key.
Version: 5.3
Requires at least: 5.8
Requires PHP: 5.6.20
Author: Automattic - Anti-spam Team
Author URI: https://automattic.com/wordpress-plugins/
License: GPLv2 or later
Text Domain: akismet
@ -30,7 +30,7 @@ You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
Copyright 2005-2022 Automattic, Inc.
Copyright 2005-2023 Automattic, Inc.
*/
// Make sure we don't expose any info if called directly
@ -39,8 +39,8 @@ if ( !function_exists( 'add_action' ) ) {
exit;
}
define( 'AKISMET_VERSION', '5.1' );
define( 'AKISMET__MINIMUM_WP_VERSION', '5.0' );
define( 'AKISMET_VERSION', '5.3' );
define( 'AKISMET__MINIMUM_WP_VERSION', '5.8' );
define( 'AKISMET__PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
define( 'AKISMET_DELETE_LIMIT', 10000 );

View File

@ -1,4 +1,4 @@
=== Akismet Anti-Spam ===
=== Akismet Anti-spam ===
== Archived Changelog Entries ==

View File

@ -59,11 +59,11 @@ class Akismet_Admin {
add_filter( 'plugin_action_links', array( 'Akismet_Admin', 'plugin_action_links' ), 10, 2 );
add_filter( 'comment_row_actions', array( 'Akismet_Admin', 'comment_row_action' ), 10, 2 );
add_filter( 'plugin_action_links_'.plugin_basename( plugin_dir_path( __FILE__ ) . 'akismet.php'), array( 'Akismet_Admin', 'admin_plugin_settings_link' ) );
add_filter( 'wxr_export_skip_commentmeta', array( 'Akismet_Admin', 'exclude_commentmeta_from_export' ), 10, 3 );
add_filter( 'all_plugins', array( 'Akismet_Admin', 'modify_plugin_description' ) );
// priority=1 because we need ours to run before core's comment anonymizer runs, and that's registered at priority=10
@ -85,7 +85,7 @@ class Akismet_Admin {
if ( function_exists( 'wp_add_privacy_policy_content' ) ) {
wp_add_privacy_policy_content(
__( 'Akismet', 'akismet' ),
__( 'We collect information about visitors who comment on Sites that use our Akismet anti-spam service. The information we collect depends on how the User sets up Akismet for the Site, but typically includes the commenter\'s IP address, user agent, referrer, and Site URL (along with other information directly provided by the commenter such as their name, username, email address, and the comment itself).', 'akismet' )
__( 'We collect information about visitors who comment on Sites that use our Akismet Anti-spam service. The information we collect depends on how the User sets up Akismet for the Site, but typically includes the commenter\'s IP address, user agent, referrer, and Site URL (along with other information directly provided by the commenter such as their name, username, email address, and the comment itself).', 'akismet' )
);
}
}
@ -102,21 +102,21 @@ class Akismet_Admin {
if ( !current_user_can( 'manage_options' ) )
return;
}
public static function admin_plugin_settings_link( $links ) {
public static function admin_plugin_settings_link( $links ) {
$settings_link = '<a href="'.esc_url( self::get_page_url() ).'">'.__('Settings', 'akismet').'</a>';
array_unshift( $links, $settings_link );
return $links;
array_unshift( $links, $settings_link );
return $links;
}
public static function load_menu() {
if ( class_exists( 'Jetpack' ) ) {
$hook = add_submenu_page( 'jetpack', __( 'Akismet Anti-Spam' , 'akismet'), __( 'Akismet Anti-Spam' , 'akismet'), 'manage_options', 'akismet-key-config', array( 'Akismet_Admin', 'display_page' ) );
$hook = add_submenu_page( 'jetpack', __( 'Akismet Anti-spam', 'akismet' ), __( 'Akismet Anti-spam', 'akismet' ), 'manage_options', 'akismet-key-config', array( 'Akismet_Admin', 'display_page' ) );
}
else {
$hook = add_options_page( __('Akismet Anti-Spam', 'akismet'), __('Akismet Anti-Spam', 'akismet'), 'manage_options', 'akismet-key-config', array( 'Akismet_Admin', 'display_page' ) );
$hook = add_options_page( __( 'Akismet Anti-spam', 'akismet' ), __( 'Akismet Anti-spam', 'akismet' ), 'manage_options', 'akismet-key-config', array( 'Akismet_Admin', 'display_page' ) );
}
if ( $hook ) {
add_action( "load-$hook", array( 'Akismet_Admin', 'admin_help' ) );
}
@ -134,12 +134,23 @@ class Akismet_Admin {
'jetpack_page_akismet-key-config',
'plugins.php',
) ) ) ) {
wp_register_style( 'akismet.css', plugin_dir_url( __FILE__ ) . '_inc/akismet.css', array(), AKISMET_VERSION );
wp_enqueue_style( 'akismet.css');
$akismet_css_path = is_rtl() ? '_inc/rtl/akismet-rtl.css' : '_inc/akismet.css';
wp_register_style( 'akismet', plugin_dir_url( __FILE__ ) . $akismet_css_path, array(), filemtime( dirname( __FILE__ ) . '/' . $akismet_css_path ) );
wp_enqueue_style( 'akismet' );
wp_register_script( 'akismet.js', plugin_dir_url( __FILE__ ) . '_inc/akismet.js', array('jquery'), AKISMET_VERSION );
wp_register_style( 'akismet-font-inter', plugin_dir_url( __FILE__ ) . '_inc/fonts/inter.css', array(), filemtime( dirname( __FILE__ ) . '/_inc/fonts/inter.css' ) );
wp_enqueue_style( 'akismet-font-inter' );
$akismet_admin_css_path = is_rtl() ? '_inc/rtl/akismet-admin-rtl.css' : '_inc/akismet-admin.css';
wp_register_style( 'akismet-admin', plugin_dir_url( __FILE__ ) . $akismet_admin_css_path, array(), filemtime( dirname( __FILE__ ) . '/' . $akismet_admin_css_path ) );
wp_enqueue_style( 'akismet-admin' );
wp_register_script( 'akismet.js', plugin_dir_url( __FILE__ ) . '_inc/akismet.js', array( 'jquery' ), AKISMET_VERSION );
wp_enqueue_script( 'akismet.js' );
wp_register_script( 'akismet-admin.js', plugin_dir_url( __FILE__ ) . '_inc/akismet-admin.js', array(), filemtime( dirname( __FILE__ ) . '/_inc/akismet-admin.js' ) );
wp_enqueue_script( 'akismet-admin.js' );
$inline_js = array(
'comment_author_url_nonce' => wp_create_nonce( 'comment_author_url_nonce' ),
'strings' => array(
@ -293,7 +304,7 @@ class Akismet_Admin {
if ( Akismet::predefined_api_key() ) {
return false; //shouldn't have option to save key if already defined
}
$new_key = preg_replace( '/[^a-f0-9]/i', '', $_POST['key'] );
$old_key = Akismet::get_api_key();
@ -315,11 +326,11 @@ class Akismet_Admin {
if ( $key_status == 'valid' ) {
$akismet_user = self::get_akismet_user( $api_key );
if ( $akismet_user ) {
if ( $akismet_user ) {
if ( in_array( $akismet_user->status, array( 'active', 'active-dunning', 'no-sub' ) ) )
update_option( 'wordpress_api_key', $api_key );
if ( $akismet_user->status == 'active' )
self::$notices['status'] = 'new-key-valid';
elseif ( $akismet_user->status == 'notice' )
@ -392,7 +403,7 @@ class Akismet_Admin {
$link = '';
$comments_count = wp_count_comments();
echo '</div>';
echo '<div class="alignleft actions">';
@ -433,7 +444,7 @@ class Akismet_Admin {
if ( ! ( isset( $_GET['recheckqueue'] ) || ( isset( $_REQUEST['action'] ) && 'akismet_recheck_queue' == $_REQUEST['action'] ) ) ) {
return;
}
if ( ! wp_verify_nonce( $_POST['nonce'], 'akismet_check_for_spam' ) ) {
wp_send_json( array(
'error' => __( 'You don&#8217;t have permission to do that.', 'akismet' ),
@ -454,10 +465,10 @@ class Akismet_Admin {
exit;
}
}
public static function recheck_queue_portion( $start = 0, $limit = 100 ) {
global $wpdb;
$paginate = '';
if ( $limit <= 0 ) {
@ -471,7 +482,7 @@ class Akismet_Admin {
$moderation = $wpdb->get_col( $wpdb->prepare( "SELECT * FROM {$wpdb->comments} WHERE comment_approved = '0' LIMIT %d OFFSET %d", $limit, $start ) );
$result_counts = array(
'processed' => count( $moderation ),
'processed' => is_countable( $moderation ) ? count( $moderation ) : 0,
'spam' => 0,
'ham' => 0,
'error' => 0,
@ -563,15 +574,15 @@ class Akismet_Admin {
echo '<span class="akismet-status" commentid="'.$comment->comment_ID.'"><a href="comment.php?action=editcomment&amp;c='.$comment->comment_ID.'#akismet-status" title="' . esc_attr__( 'View comment history' , 'akismet') . '">'.esc_html( $desc ).'</a></span>';
$show_user_comments_option = get_option( 'akismet_show_user_comments_approved' );
if ( $show_user_comments_option === false ) {
// Default to active if the user hasn't made a decision.
$show_user_comments_option = '1';
}
$show_user_comments = apply_filters( 'akismet_show_user_comments_approved', $show_user_comments_option );
$show_user_comments = $show_user_comments === 'false' ? false : $show_user_comments; //option used to be saved as 'false' / 'true'
if ( $show_user_comments ) {
$comment_count = Akismet::get_user_comments_approved( $comment->user_id, $comment->comment_author_email, $comment->comment_author, $comment->comment_author_url );
$comment_count = intval( $comment_count );
@ -592,7 +603,7 @@ class Akismet_Admin {
// Old versions of Akismet stored the message as a literal string in the commentmeta.
// New versions don't do that for two reasons:
// 1) Save space.
// 2) The message can be translated into the current language of the blog, not stuck
// 2) The message can be translated into the current language of the blog, not stuck
// in the language of the blog when the comment was made.
$message = esc_html( $row['message'] );
} else if ( ! empty( $row['event'] ) ) {
@ -679,7 +690,7 @@ class Akismet_Admin {
echo '<p>';
if ( isset( $row['time'] ) ) {
$time = gmdate( 'D d M Y @ h:i:s a', $row['time'] ) . ' GMT';
$time = gmdate( 'D d M Y @ h:i:s a', (int) $row['time'] ) . ' GMT';
/* translators: The placeholder is an amount of time, like "7 seconds" or "3 days" returned by the function human_time_diff(). */
$time_html = '<span style="color: #999;" alt="' . esc_attr( $time ) . '" title="' . esc_attr( $time ) . '">' . sprintf( esc_html__( '%s ago', 'akismet' ), human_time_diff( $row['time'] ) ) . '</span>';
@ -738,16 +749,16 @@ class Akismet_Admin {
// Check connectivity between the WordPress blog and Akismet's servers.
// Returns an associative array of server IP addresses, where the key is the IP address, and value is true (available) or false (unable to connect).
public static function check_server_ip_connectivity() {
$servers = $ips = array();
// Some web hosts may disable this function
if ( function_exists('gethostbynamel') ) {
if ( function_exists( 'gethostbynamel' ) ) {
$ips = gethostbynamel( 'rest.akismet.com' );
if ( $ips && is_array($ips) && count($ips) ) {
$api_key = Akismet::get_api_key();
foreach ( $ips as $ip ) {
$response = Akismet::verify_key( $api_key, $ip );
// even if the key is invalid, at least we know we have connectivity
@ -758,13 +769,13 @@ class Akismet_Admin {
}
}
}
return $servers;
}
// Simpler connectivity check
public static function check_server_connectivity($cache_timeout = 86400) {
$debug = array();
$debug[ 'PHP_VERSION' ] = PHP_VERSION;
$debug[ 'WORDPRESS_VERSION' ] = $GLOBALS['wp_version'];
@ -772,7 +783,7 @@ class Akismet_Admin {
$debug[ 'AKISMET__PLUGIN_DIR' ] = AKISMET__PLUGIN_DIR;
$debug[ 'SITE_URL' ] = site_url();
$debug[ 'HOME_URL' ] = home_url();
$servers = get_option('akismet_available_servers');
if ( (time() - get_option('akismet_connectivity_time') < $cache_timeout) && $servers !== false ) {
$servers = self::check_server_ip_connectivity();
@ -790,16 +801,16 @@ class Akismet_Admin {
$debug[ 'gethostbynamel' ] = function_exists('gethostbynamel') ? 'exists' : 'not here';
$debug[ 'Servers' ] = $servers;
$debug[ 'Test Connection' ] = $response;
Akismet::log( $debug );
if ( $response && 'connected' == wp_remote_retrieve_body( $response ) )
return true;
return false;
}
// Check the server connectivity and store the available servers in an option.
// Check the server connectivity and store the available servers in an option.
public static function get_server_connectivity($cache_timeout = 86400) {
return self::check_server_connectivity( $cache_timeout );
}
@ -814,10 +825,10 @@ class Akismet_Admin {
// Exclude comments that are not pending. This would happen if someone manually approved or spammed a comment
// that was waiting to be checked. The akismet_error meta entry will eventually be removed by the cron recheck job.
'status' => 'hold',
// This is the commentmeta that is saved when a comment couldn't be checked.
'meta_key' => 'akismet_error',
// We only need to know whether at least one comment is waiting for a check.
'number' => 1,
) );
@ -837,7 +848,7 @@ class Akismet_Admin {
return add_query_arg( $args, menu_page_url( 'akismet-key-config', false ) );
}
public static function get_akismet_user( $api_key ) {
$akismet_user = false;
@ -851,7 +862,7 @@ class Akismet_Admin {
return $akismet_user;
}
public static function get_stats( $api_key ) {
$stat_totals = array();
@ -865,7 +876,7 @@ class Akismet_Admin {
return $stat_totals;
}
public static function verify_wpcom_key( $api_key, $user_id, $extra = array() ) {
$akismet_account = Akismet::http_post( Akismet::build_query( array_merge( array(
'user_id' => $user_id,
@ -877,23 +888,23 @@ class Akismet_Admin {
$akismet_account = json_decode( $akismet_account[1] );
Akismet::log( compact( 'akismet_account' ) );
return $akismet_account;
}
public static function connect_jetpack_user() {
if ( $jetpack_user = self::get_jetpack_user() ) {
if ( isset( $jetpack_user['user_id'] ) && isset( $jetpack_user['api_key'] ) ) {
$akismet_user = self::verify_wpcom_key( $jetpack_user['api_key'], $jetpack_user['user_id'], array( 'action' => 'connect_jetpack_user' ) );
if ( is_object( $akismet_user ) ) {
self::save_key( $akismet_user->api_key );
return in_array( $akismet_user->status, array( 'active', 'active-dunning', 'no-sub' ) );
}
}
}
return false;
}
@ -964,18 +975,18 @@ class Akismet_Admin {
self::display_configuration_page();
return;
}
//the user can choose to auto connect their API key by clicking a button on the akismet done page
//if jetpack, get verified api key by using connected wpcom user id
//if no jetpack, get verified api key by using an akismet token
//if no jetpack, get verified api key by using an akismet token
$akismet_user = false;
if ( isset( $_GET['token'] ) && preg_match('/^(\d+)-[0-9a-f]{20}$/', $_GET['token'] ) )
$akismet_user = self::verify_wpcom_key( '', '', array( 'token' => $_GET['token'] ) );
elseif ( $jetpack_user = self::get_jetpack_user() )
$akismet_user = self::verify_wpcom_key( $jetpack_user['api_key'], $jetpack_user['user_id'] );
if ( isset( $_GET['action'] ) ) {
if ( $_GET['action'] == 'save-key' ) {
if ( is_object( $akismet_user ) ) {
@ -1009,7 +1020,7 @@ class Akismet_Admin {
public static function display_configuration_page() {
$api_key = Akismet::get_api_key();
$akismet_user = self::get_akismet_user( $api_key );
if ( ! $akismet_user ) {
// This could happen if the user's key became invalid after it was previously valid and successfully set up.
self::$notices['status'] = 'existing-key-invalid';
@ -1024,7 +1035,7 @@ class Akismet_Admin {
if ( get_option( 'akismet_strictness' ) === false ) {
add_option( 'akismet_strictness', ( get_option( 'akismet_discard_month' ) === 'false' ? '0' : '1' ) );
}
// Sync the local "Total spam blocked" count with the authoritative count from the server.
if ( isset( $stat_totals['all'], $stat_totals['all']->spam ) ) {
update_option( 'akismet_spam_count', $stat_totals['all']->spam );
@ -1050,11 +1061,11 @@ class Akismet_Admin {
elseif ( $total_in_minutes >= 30 )
$time_saved = $cleaning_up . ' ' . sprintf( _n( 'Akismet has saved you %d minute!', 'Akismet has saved you %d minutes!', $total_in_minutes, 'akismet' ), $total_in_minutes );
}
$notices[] = array( 'type' => 'active-notice', 'time_saved' => $time_saved );
}
}
if ( !isset( self::$notices['status'] ) && in_array( $akismet_user->status, array( 'cancelled', 'suspended', 'missing', 'no-sub' ) ) ) {
$notices[] = array( 'type' => $akismet_user->status );
}
@ -1081,10 +1092,11 @@ class Akismet_Admin {
$notices[] = array( 'type' => 'new-key-invalid' );
$notices[] = array( 'type' => 'existing-key-invalid' );
$notices[] = array( 'type' => 'new-key-failed' );
$notices[] = array( 'type' => 'usage-limit', 'api_calls' => '15000', 'usage_limit' => '10000', 'upgrade_plan' => 'Enterprise', 'upgrade_url' => 'https://akismet.com/account/' );
$notices[] = array( 'type' => 'usage-limit', 'api_calls' => '15000', 'usage_limit' => '10000', 'upgrade_plan' => 'Enterprise', 'upgrade_url' => 'https://akismet.com/account/', 'code' => 10502 );
$notices[] = array( 'type' => 'spam-check-cron-disabled' );
$notices[] = array( 'type' => 'alert', 'code' => 123 );
*/
Akismet::log( compact( 'stat_totals', 'akismet_user' ) );
Akismet::view( 'config', compact( 'api_key', 'akismet_user', 'stat_totals', 'notices' ) );
}
@ -1114,18 +1126,18 @@ class Akismet_Admin {
elseif ( $hook_suffix == 'edit-comments.php' && wp_next_scheduled( 'akismet_schedule_cron_recheck' ) ) {
self::display_spam_check_warning();
}
if ( isset( $_GET['akismet_recheck_complete'] ) ) {
$recheck_count = (int) $_GET['recheck_count'];
$spam_count = (int) $_GET['spam_count'];
if ( $recheck_count === 0 ) {
$message = __( 'There were no comments to check. Akismet will only check comments awaiting moderation.', 'akismet' );
}
else {
$message = sprintf( _n( 'Akismet checked %s comment.', 'Akismet checked %s comments.', $recheck_count, 'akismet' ), number_format( $recheck_count ) );
$message .= ' ';
if ( $spam_count === 0 ) {
$message .= __( 'No comments were caught as spam.', 'akismet' );
}
@ -1133,7 +1145,7 @@ class Akismet_Admin {
$message .= sprintf( _n( '%s comment was caught as spam.', '%s comments were caught as spam.', $spam_count, 'akismet' ), number_format( $spam_count ) );
}
}
echo '<div class="notice notice-success"><p>' . esc_html( $message ) . '</p></div>';
}
else if ( isset( $_GET['akismet_recheck_error'] ) ) {
@ -1149,25 +1161,25 @@ class Akismet_Admin {
foreach ( self::$notices as $index => $type ) {
if ( is_object( $type ) ) {
$notice_header = $notice_text = '';
if ( property_exists( $type, 'notice_header' ) ) {
$notice_header = wp_kses( $type->notice_header, self::$allowed );
}
if ( property_exists( $type, 'notice_text' ) ) {
$notice_text = wp_kses( $type->notice_text, self::$allowed );
}
if ( property_exists( $type, 'status' ) ) {
$type = wp_kses( $type->status, self::$allowed );
Akismet::view( 'notice', compact( 'type', 'notice_header', 'notice_text' ) );
unset( self::$notices[ $index ] );
}
}
else {
Akismet::view( 'notice', compact( 'type' ) );
unset( self::$notices[ $index ] );
}
}
@ -1193,13 +1205,13 @@ class Akismet_Admin {
if ( !$xml->isError() ) {
$responses = $xml->getResponse();
if ( count( $responses ) > 1 ) {
if ( ( is_countable( $responses ) ? count( $responses ) : 0 ) > 1 ) {
// Due to a quirk in how Jetpack does multi-calls, the response order
// can't be trusted to match the call order. It's a good thing our
// return values can be mostly differentiated from each other.
$first_response_value = array_shift( $responses[0] );
$second_response_value = array_shift( $responses[1] );
// If WPCOM ever reaches 100 billion users, this will fail. :-)
if ( preg_match( '/^[a-f0-9]{12}$/i', $first_response_value ) ) {
$api_key = $first_response_value;
@ -1209,13 +1221,13 @@ class Akismet_Admin {
$api_key = $second_response_value;
$user_id = (int) $first_response_value;
}
return compact( 'api_key', 'user_id' );
}
}
return false;
}
/**
* Some commentmeta isn't useful in an export file. Suppress it (when supported).
*
@ -1228,10 +1240,10 @@ class Akismet_Admin {
if ( in_array( $key, array( 'akismet_as_submitted', 'akismet_rechecking', 'akismet_delayed_moderation_email' ) ) ) {
return true;
}
return $exclude;
}
/**
* When Akismet is active, remove the "Activate Akismet" step from the plugin description.
*/
@ -1244,7 +1256,7 @@ class Akismet_Admin {
$all_plugins['akismet/akismet.php']['Description'] = __( 'Used by millions, Akismet is quite possibly the best way in the world to <strong>protect your blog from spam</strong>. It keeps your site protected even while you sleep. To get started, just go to <a href="admin.php?page=akismet-key-config">your Akismet Settings page</a> to set up your API key.', 'akismet' );
}
}
return $all_plugins;
}
@ -1253,7 +1265,7 @@ class Akismet_Admin {
update_option( 'akismet_comment_form_privacy_notice', $state );
}
}
public static function register_personal_data_eraser( $erasers ) {
$erasers['akismet'] = array(
'eraser_friendly_name' => __( 'Akismet', 'akismet' ),
@ -1262,14 +1274,14 @@ class Akismet_Admin {
return $erasers;
}
/**
* When a user requests that their personal data be removed, Akismet has a duty to discard
* any personal data we store outside of the comment itself. Right now, that is limited
* to the copy of the comment we store in the akismet_as_submitted commentmeta.
*
* FWIW, this information would be automatically deleted after 15 days.
*
*
* @param $email_address string The email address of the user who has requested erasure.
* @param $page int This function can (and will) be called multiple times to prevent timeouts,
* so this argument is used for pagination.
@ -1278,7 +1290,7 @@ class Akismet_Admin {
*/
public static function erase_personal_data( $email_address, $page = 1 ) {
$items_removed = false;
$number = 50;
$page = (int) $page;
@ -1294,7 +1306,7 @@ class Akismet_Admin {
foreach ( (array) $comments as $comment ) {
$comment_as_submitted = get_comment_meta( $comment->comment_ID, 'akismet_as_submitted', true );
if ( $comment_as_submitted ) {
delete_comment_meta( $comment->comment_ID, 'akismet_as_submitted' );
$items_removed = true;
@ -1302,8 +1314,8 @@ class Akismet_Admin {
}
// Tell core if we have more comments to work on still
$done = count( $comments ) < $number;
$done = ( is_countable( $comments ) ? count( $comments ) : 0 ) < $number;
return array(
'items_removed' => $items_removed,
'items_retained' => false, // always false in this example
@ -1311,4 +1323,13 @@ class Akismet_Admin {
'done' => $done,
);
}
/**
* Return an array of HTML elements that are allowed in a notice.
*
* @return array
*/
public static function get_notice_kses_allowed_elements() {
return self::$allowed;
}
}

View File

@ -79,6 +79,7 @@ class Akismet_Widget extends WP_Widget {
}
function update( $new_instance, $old_instance ) {
$instance = array();
$instance['title'] = strip_tags( $new_instance['title'] );
return $instance;
}

View File

@ -73,8 +73,21 @@ class Akismet {
add_filter( 'frm_akismet_values', array( 'Akismet', 'prepare_custom_form_values' ) );
// Fluent Forms
/*
* The Fluent Forms hook names were updated in version 5.0.0. The last version that supported
* the original hook names was 4.3.25, and version 4.3.25 was tested up to WordPress version 6.1.
*
* The legacy hooks are fired before the new hooks. See
* https://github.com/fluentform/fluentform/commit/cc45341afcae400f217470a7bbfb15efdd80454f
*
* The legacy Fluent Forms hooks will be removed when Akismet no longer supports WordPress version 6.1.
* This will provide compatibility with previous versions of Fluent Forms for a reasonable amount of time.
*/
add_filter( 'fluentform_form_element_start', array( 'Akismet', 'output_custom_form_fields' ) );
add_filter( 'fluentform_akismet_fields', array( 'Akismet', 'prepare_custom_form_values' ), 10, 2 );
// Current Fluent Form hooks.
add_filter( 'fluentform/form_element_start', array( 'Akismet', 'output_custom_form_fields' ) );
add_filter( 'fluentform/akismet_fields', array( 'Akismet', 'prepare_custom_form_values' ), 10, 2 );
add_action( 'update_option_wordpress_api_key', array( 'Akismet', 'updated_option' ), 10, 2 );
add_action( 'add_option_wordpress_api_key', array( 'Akismet', 'added_option' ), 10, 2 );
@ -468,7 +481,7 @@ class Akismet {
}
// Prepared as strings since comment_id is an unsigned BIGINT, and using %d will constrain the value to the maximum signed BIGINT.
$format_string = implode( ", ", array_fill( 0, count( $comment_ids ), '%s' ) );
$format_string = implode( ', ', array_fill( 0, is_countable( $comment_ids ) ? count( $comment_ids ) : 0, '%s' ) );
$wpdb->query( $wpdb->prepare( "DELETE FROM {$wpdb->comments} WHERE comment_id IN ( " . $format_string . " )", $comment_ids ) );
$wpdb->query( $wpdb->prepare( "DELETE FROM {$wpdb->commentmeta} WHERE comment_id IN ( " . $format_string . " )", $comment_ids ) );
@ -479,7 +492,7 @@ class Akismet {
}
clean_comment_cache( $comment_ids );
do_action( 'akismet_delete_comment_batch', count( $comment_ids ) );
do_action( 'akismet_delete_comment_batch', is_countable( $comment_ids ) ? count( $comment_ids ) : 0 );
}
if ( apply_filters( 'akismet_optimize_table', ( mt_rand(1, 5000) == 11), $wpdb->comments ) ) // lucky number
@ -509,7 +522,7 @@ class Akismet {
do_action( 'akismet_batch_delete_count', __FUNCTION__ );
}
do_action( 'akismet_delete_commentmeta_batch', count( $comment_ids ) );
do_action( 'akismet_delete_commentmeta_batch', is_countable( $comment_ids ) ? count( $comment_ids ) : 0 );
}
if ( apply_filters( 'akismet_optimize_table', ( mt_rand(1, 5000) == 11), $wpdb->commentmeta ) ) // lucky number
@ -1151,6 +1164,7 @@ class Akismet {
// return a comma-separated list of role names for the given user
public static function get_user_roles( $user_id ) {
$comment_user = null;
$roles = false;
if ( !class_exists('WP_User') )
@ -1159,7 +1173,7 @@ class Akismet {
if ( $user_id > 0 ) {
$comment_user = new WP_User( $user_id );
if ( isset( $comment_user->roles ) )
$roles = join( ',', $comment_user->roles );
$roles = implode( ',', $comment_user->roles );
}
if ( is_multisite() && is_super_admin( $user_id ) ) {
@ -1167,7 +1181,7 @@ class Akismet {
$roles = 'super_admin';
} else {
$comment_user->roles[] = 'super_admin';
$roles = join( ',', $comment_user->roles );
$roles = implode( ',', $comment_user->roles );
}
}
@ -1426,6 +1440,11 @@ class Akismet {
}
public static function output_custom_form_fields( $post_id ) {
if ( 'fluentform/form_element_start' === current_filter() && did_action( 'fluentform_form_element_start' ) ) {
// Already did this via the legacy filter.
return;
}
// phpcs:ignore WordPress.Security.EscapeOutput
echo self::get_akismet_form_fields();
}
@ -1451,6 +1470,11 @@ class Akismet {
* @return array $form
*/
public static function prepare_custom_form_values( $form, $data = null ) {
if ( 'fluentform/akismet_fields' === current_filter() && did_filter( 'fluentform_akismet_fields' ) ) {
// Already updated the form fields via the legacy filter.
return $form;
}
if ( is_null( $data ) ) {
// phpcs:ignore WordPress.Security.NonceVerification.Missing
$data = $_POST;
@ -1592,6 +1616,7 @@ p {
}
public static function pre_check_pingback( $method ) {
$pingback_args = array();
if ( $method !== 'pingback.ping' )
return;
@ -1616,7 +1641,7 @@ p {
if ( 0 === $call_count ) {
// Only pass along the number of entries in the multicall the first time we see it.
$multicall_count = count( $wp_xmlrpc_server->message->params );
$multicall_count = is_countable( $wp_xmlrpc_server->message->params ) ? count( $wp_xmlrpc_server->message->params ) : 0;
}
/*

View File

@ -1,9 +1,9 @@
=== Akismet Anti-Spam: Spam Protection ===
Contributors: matt, ryan, andy, mdawaffe, tellyworth, josephscott, lessbloat, eoigal, cfinke, automattic, jgs, procifer, stephdau, kbrownkd, akismetantispam
=== Akismet Anti-spam: Spam Protection ===
Contributors: matt, ryan, andy, mdawaffe, tellyworth, josephscott, lessbloat, eoigal, cfinke, automattic, jgs, procifer, stephdau, kbrownkd, bluefuton, akismetantispam
Tags: comments, spam, antispam, anti-spam, contact form, anti spam, comment moderation, comment spam, contact form spam, spam comments
Requires at least: 5.0
Tested up to: 6.2
Stable tag: 5.1
Requires at least: 5.8
Tested up to: 6.3
Stable tag: 5.3
License: GPLv2 or later
The best anti-spam protection to block spam comments and spam in a contact form. The most trusted antispam solution for WordPress and WooCommerce.
@ -32,12 +32,31 @@ Upload the Akismet plugin to your blog, activate it, and then enter your Akismet
== Changelog ==
= 5.3 =
*Release Date - 14 September 2023*
* Improve display of user notices.
* Add stylesheets for RTL languages.
* Remove initial disabled state from 'Save changes' button.
* Improve accessibility of API key entry form.
* Add new filter hooks for Fluent Forms.
* Fix issue with PHP 8.1 compatibility.
= 5.2 =
*Release Date - 21 June 2023*
* Visual refresh of Akismet stats.
* Improve PHP 8.1 compatibility.
* Improve appearance of plugin to match updated stats.
* Change minimum supported PHP version to 5.6 to match WordPress.
* Drop IE11 support and update minimum WordPress version to 5.8 (where IE11 support was removed from WP Core).
= 5.1 =
*Release Date - 20 March 2023*
* Removed unnecessary limit notices from admin page.
* Improved spam detection by including post taxonomies in the comment-check call.
* Removed API keys from stats iframes to avoid possible inadvertant exposure.
* Removed API keys from stats iframes to avoid possible inadvertent exposure.
= 5.0.2 =
*Release Date - 1 December 2022*

View File

@ -7,9 +7,7 @@
<div id="akismet-plugin-container">
<div class="akismet-masthead">
<div class="akismet-masthead__inside-container">
<div class="akismet-masthead__logo-container">
<img class="akismet-masthead__logo" src="<?php echo esc_url( plugins_url( '../_inc/img/logo-full-2x.png', __FILE__ ) ); ?>" alt="Akismet" />
</div>
<?php Akismet::view( 'logo' ); ?>
</div>
</div>
<div class="akismet-lower">
@ -24,37 +22,45 @@
<div class="akismet-card">
<div class="akismet-section-header">
<div class="akismet-section-header__label">
<h2 class="akismet-section-header__label">
<span><?php esc_html_e( 'Statistics', 'akismet' ); ?></span>
</div>
</h2>
<?php if ( $stat_totals && isset( $stat_totals['all'] ) && (int) $stat_totals['all']->spam > 0 ) : ?>
<div class="akismet-section-header__actions">
<a href="<?php echo esc_url( Akismet_Admin::get_page_url( 'stats' ) ); ?>">
<?php esc_html_e( 'Detailed Stats', 'akismet' ); ?>
<?php esc_html_e( 'Detailed stats', 'akismet' ); ?>
</a>
</div>
</div> <!-- close akismet-section-header -->
<div class="akismet-new-snapshot">
<iframe allowtransparency="true" scrolling="no" frameborder="0" style="width: 100%; height: 220px; overflow: hidden;" src="<?php echo esc_url( sprintf( 'https://tools.akismet.com/1.0/snapshot.php?blog=%s&token=%s&height=200&locale=%s', urlencode( get_option( 'home' ) ), urlencode( Akismet::get_access_token() ), get_locale() ) ); ?>"></iframe>
<ul>
<li>
<h3><?php esc_html_e( 'Past six months' , 'akismet');?></h3>
<span><?php echo number_format( $stat_totals['6-months']->spam );?></span>
<?php echo esc_html( _n( 'Spam blocked', 'Spam blocked', $stat_totals['6-months']->spam, 'akismet' ) ); ?>
<?php /* name attribute on iframe is used as a cache-buster here to force Firefox to load the new style charts: https://bugzilla.mozilla.org/show_bug.cgi?id=356558 */ ?>
<div class="akismet-new-snapshot__chart">
<iframe id="stats-iframe" allowtransparency="true" scrolling="no" frameborder="0" style="width: 100%; height: 220px; overflow: hidden;" src="<?php echo esc_url( sprintf( 'https://tools.akismet.com/1.0/snapshot.php?blog=%s&token=%s&height=200&locale=%s&is_redecorated=1', urlencode( get_option( 'home' ) ), urlencode( Akismet::get_access_token() ), get_locale() ) ); ?>" name="<?php echo esc_attr( 'snapshot-' . filemtime( __FILE__ ) ); ?>" title="<?php echo esc_attr__( 'Akismet stats' ); ?>"></iframe>
</div>
<ul class="akismet-new-snapshot__list">
<li class="akismet-new-snapshot__item">
<h3 class="akismet-new-snapshot__header"><?php esc_html_e( 'Past six months', 'akismet' ); ?></h3>
<span class="akismet-new-snapshot__number"><?php echo number_format( $stat_totals['6-months']->spam ); ?></span>
<span class="akismet-new-snapshot__text"><?php echo esc_html( _n( 'Spam blocked', 'Spam blocked', $stat_totals['6-months']->spam, 'akismet' ) ); ?></span>
</li>
<li>
<h3><?php esc_html_e( 'All time' , 'akismet');?></h3>
<span><?php echo number_format( $stat_totals['all']->spam );?></span>
<?php echo esc_html( _n( 'Spam blocked', 'Spam blocked', $stat_totals['all']->spam, 'akismet' ) ); ?>
<li class="akismet-new-snapshot__item">
<h3 class="akismet-new-snapshot__header"><?php esc_html_e( 'All time', 'akismet' ); ?></h3>
<span class="akismet-new-snapshot__number"><?php echo number_format( $stat_totals['all']->spam ); ?></span>
<span class="akismet-new-snapshot__text"><?php echo esc_html( _n( 'Spam blocked', 'Spam blocked', $stat_totals['all']->spam, 'akismet' ) ); ?></span>
</li>
<li>
<h3><?php esc_html_e( 'Accuracy' , 'akismet');?></h3>
<span><?php echo floatval( $stat_totals['all']->accuracy ); ?>%</span>
<?php printf( _n( '%s missed spam', '%s missed spam', $stat_totals['all']->missed_spam, 'akismet' ), number_format( $stat_totals['all']->missed_spam ) ); ?>
|
<?php printf( _n( '%s false positive', '%s false positives', $stat_totals['all']->false_positives, 'akismet' ), number_format( $stat_totals['all']->false_positives ) ); ?>
<li class="akismet-new-snapshot__item">
<h3 class="akismet-new-snapshot__header"><?php esc_html_e( 'Accuracy', 'akismet' ); ?></h3>
<span class="akismet-new-snapshot__number"><?php echo floatval( $stat_totals['all']->accuracy ); ?>%</span>
<span class="akismet-new-snapshot__text">
<?php
/* translators: %s: number of spam missed by Akismet */
echo esc_html( sprintf( _n( '%s missed spam', '%s missed spam', $stat_totals['all']->missed_spam, 'akismet' ), number_format( $stat_totals['all']->missed_spam ) ) ) . ', ';
/* translators: %s: number of false positive spam flagged by Akismet */
echo esc_html( sprintf( _n( '%s false positive', '%s false positives', $stat_totals['all']->false_positives, 'akismet' ), number_format( $stat_totals['all']->false_positives ) ) );
?>
</span>
</li>
</ul>
</div> <!-- close akismet-new-snapshot -->
@ -62,7 +68,7 @@
<?php else : ?>
</div> <!-- close akismet-section-header -->
<div class="inside">
<p><?php esc_html_e( 'Akismet is active and ready to stop spam. Your site&#8217;s spam statistics will be displayed here.', 'akismet' ); ?></p>
<p class="akismet-awaiting-stats"><?php esc_html_e( 'Akismet is active and ready to stop spam. Your site&#8217;s spam statistics will be displayed here.', 'akismet' ); ?></p>
</div>
<?php endif; ?>
@ -71,89 +77,105 @@
<?php if ( $akismet_user ) : ?>
<div class="akismet-card">
<div class="akismet-section-header">
<div class="akismet-section-header__label">
<h2 class="akismet-section-header__label">
<span><?php esc_html_e( 'Settings' , 'akismet'); ?></span>
</div>
</h2>
</div>
<div class="inside">
<form action="<?php echo esc_url( Akismet_Admin::get_page_url() ); ?>" method="POST">
<table cellspacing="0" class="akismet-settings">
<tbody>
<?php if ( ! Akismet::predefined_api_key() ) { ?>
<tr>
<th class="akismet-api-key" width="10%" align="left" scope="row">
<label for="key"><?php esc_html_e( 'API Key', 'akismet' ); ?></label>
</th>
<td width="5%"/>
<td align="left">
<form action="<?php echo esc_url( Akismet_Admin::get_page_url() ); ?>" autocomplete="off" method="POST" id="akismet-settings-form">
<div class="akismet-settings">
<?php if ( ! Akismet::predefined_api_key() ) : ?>
<div class="akismet-settings__row">
<h3 class="akismet-settings__row-title">
<label class="akismet-settings__row-label" for="key"><?php esc_html_e( 'API key', 'akismet' ); ?></label>
</h3>
<div class="akismet-settings__row-input">
<span class="api-key"><input id="key" name="key" type="text" size="15" value="<?php echo esc_attr( get_option('wordpress_api_key') ); ?>" class="<?php echo esc_attr( 'regular-text code ' . $akismet_user->status ); ?>"></span>
</td>
</tr>
<?php } ?>
<?php if ( isset( $_GET['ssl_status'] ) ) { ?>
<tr>
<th align="left" scope="row"><?php esc_html_e( 'SSL Status', 'akismet' ); ?></th>
<td></td>
<td align="left">
<p>
<?php
</div>
</div>
<?php endif; ?>
<?php if ( isset( $_GET['ssl_status'] ) ) : ?>
<div class="akismet-settings__row">
<div class="akismet-settings__row-text">
<h3 class="akismet-settings__row-title"><?php esc_html_e( 'SSL status', 'akismet' ); ?></h3>
<div class="akismet-settings__row-description">
<?php if ( ! wp_http_supports( array( 'ssl' ) ) ) : ?>
<strong><?php esc_html_e( 'Disabled.', 'akismet' ); ?></strong>
<?php esc_html_e( 'Your Web server cannot make SSL requests; contact your Web host and ask them to add support for SSL requests.', 'akismet' ); ?>
<?php else : ?>
<?php $ssl_disabled = get_option( 'akismet_ssl_disabled' ); ?>
if ( ! wp_http_supports( array( 'ssl' ) ) ) {
?><b><?php esc_html_e( 'Disabled.', 'akismet' ); ?></b> <?php esc_html_e( 'Your Web server cannot make SSL requests; contact your Web host and ask them to add support for SSL requests.', 'akismet' ); ?><?php
}
else {
$ssl_disabled = get_option( 'akismet_ssl_disabled' );
if ( $ssl_disabled ) {
?><b><?php esc_html_e( 'Temporarily disabled.', 'akismet' ); ?></b> <?php esc_html_e( 'Akismet encountered a problem with a previous SSL request and disabled it temporarily. It will begin using SSL for requests again shortly.', 'akismet' ); ?><?php
}
else {
?><b><?php esc_html_e( 'Enabled.', 'akismet' ); ?></b> <?php esc_html_e( 'All systems functional.', 'akismet' ); ?><?php
}
}
?>
</p>
</td>
</tr>
<?php } ?>
<tr>
<th align="left" scope="row"><?php esc_html_e('Comments', 'akismet');?></th>
<td></td>
<td align="left">
<p>
<label for="akismet_show_user_comments_approved" title="<?php esc_attr_e( 'Show approved comments' , 'akismet'); ?>">
<input
name="akismet_show_user_comments_approved"
id="akismet_show_user_comments_approved"
value="1"
type="checkbox"
<?php
// If the option isn't set, or if it's enabled ('1'), or if it was enabled a long time ago ('true'), check the checkbox.
checked( true, ( in_array( get_option( 'akismet_show_user_comments_approved' ), array( false, '1', 'true' ), true ) ) );
?>
/>
<?php esc_html_e( 'Show the number of approved comments beside each comment author', 'akismet' ); ?>
</label>
</p>
</td>
</tr>
<tr>
<th class="strictness" align="left" scope="row"><?php esc_html_e('Strictness', 'akismet'); ?></th>
<td></td>
<td align="left">
<fieldset><legend class="screen-reader-text"><span><?php esc_html_e('Akismet anti-spam strictness', 'akismet'); ?></span></legend>
<p><label for="akismet_strictness_1"><input type="radio" name="akismet_strictness" id="akismet_strictness_1" value="1" <?php checked('1', get_option('akismet_strictness')); ?> /> <?php esc_html_e('Silently discard the worst and most pervasive spam so I never see it.', 'akismet'); ?></label></p>
<p><label for="akismet_strictness_0"><input type="radio" name="akismet_strictness" id="akismet_strictness_0" value="0" <?php checked('0', get_option('akismet_strictness')); ?> /> <?php esc_html_e('Always put spam in the Spam folder for review.', 'akismet'); ?></label></p>
</fieldset>
<span class="akismet-note"><strong><?php esc_html_e('Note:', 'akismet');?></strong>
<?php if ( $ssl_disabled ) : ?>
<strong><?php esc_html_e( 'Temporarily disabled.', 'akismet' ); ?></strong>
<?php esc_html_e( 'Akismet encountered a problem with a previous SSL request and disabled it temporarily. It will begin using SSL for requests again shortly.', 'akismet' ); ?>
<?php else : ?>
<strong><?php esc_html_e( 'Enabled.', 'akismet' ); ?></strong>
<?php esc_html_e( 'All systems functional.', 'akismet' ); ?>
<?php endif; ?>
<?php endif; ?>
</div>
</div>
</div>
<?php endif; ?>
<div class="akismet-settings__row">
<div class="akismet-settings__row-text">
<h3 class="akismet-settings__row-title"><?php esc_html_e( 'Comments', 'akismet' ); ?></h3>
</div>
<div class="akismet-settings__row-input">
<label class="akismet-settings__row-input-label" for="akismet_show_user_comments_approved">
<input
name="akismet_show_user_comments_approved"
id="akismet_show_user_comments_approved"
value="1"
type="checkbox"
<?php
// If the option isn't set, or if it's enabled ('1'), or if it was enabled a long time ago ('true'), check the checkbox.
checked( true, ( in_array( get_option( 'akismet_show_user_comments_approved' ), array( false, '1', 'true' ), true ) ) );
?>
/>
<span class="akismet-settings__row-label-text">
<?php esc_html_e( 'Show the number of approved comments beside each comment author.', 'akismet' ); ?>
</span>
</label>
</div>
</div>
<div class="akismet-settings__row is-radio">
<div class="akismet-settings__row-text">
<h3 class="akismet-settings__row-title"><?php esc_html_e( 'Spam filtering', 'akismet' ); ?></h3>
</div>
<div class="akismet-settings__row-input">
<fieldset>
<legend class="screen-reader-text">
<span><?php esc_html_e( 'Akismet Anti-spam strictness', 'akismet' ); ?></span>
</legend>
<div>
<label class="akismet-settings__row-input-label" for="akismet_strictness_1">
<input type="radio" name="akismet_strictness" id="akismet_strictness_1" value="1" <?php checked( '1', get_option( 'akismet_strictness' ) ); ?> />
<span class="akismet-settings__row-label-text">
<?php esc_html_e( 'Silently discard the worst and most pervasive spam so I never see it.', 'akismet' ); ?>
</span>
</label>
</div>
<div>
<label class="akismet-settings__row-input-label" for="akismet_strictness_0">
<input type="radio" name="akismet_strictness" id="akismet_strictness_0" value="0" <?php checked( '0', get_option( 'akismet_strictness' ) ); ?> />
<span class="akismet-settings__row-label-text">
<?php esc_html_e( 'Always put spam in the Spam folder for review.', 'akismet' ); ?>
</span>
</label>
</div>
</fieldset>
<div class="akismet-settings__row-note">
<strong><?php esc_html_e( 'Note:', 'akismet' ); ?></strong>
<?php
$delete_interval = max( 1, intval( apply_filters( 'akismet_delete_comment_interval', 15 ) ) );
printf(
_n(
'Spam in the <a href="%1$s">spam folder</a> older than 1 day is deleted automatically.',
@ -164,82 +186,104 @@
admin_url( 'edit-comments.php?comment_status=spam' ),
$delete_interval
);
?>
</td>
</tr>
<tr>
<th class="comment-form-privacy-notice" align="left" scope="row"><?php esc_html_e('Privacy', 'akismet'); ?></th>
<td></td>
<td align="left">
<fieldset><legend class="screen-reader-text"><span><?php esc_html_e('Akismet privacy notice', 'akismet'); ?></span></legend>
<p><label for="akismet_comment_form_privacy_notice_display"><input type="radio" name="akismet_comment_form_privacy_notice" id="akismet_comment_form_privacy_notice_display" value="display" <?php checked('display', get_option('akismet_comment_form_privacy_notice')); ?> /> <?php esc_html_e('Display a privacy notice under your comment forms.', 'akismet'); ?></label></p>
<p><label for="akismet_comment_form_privacy_notice_hide"><input type="radio" name="akismet_comment_form_privacy_notice" id="akismet_comment_form_privacy_notice_hide" value="hide" <?php echo in_array( get_option('akismet_comment_form_privacy_notice'), array('display', 'hide') ) ? checked('hide', get_option('akismet_comment_form_privacy_notice'), false) : 'checked="checked"'; ?> /> <?php esc_html_e('Do not display privacy notice.', 'akismet'); ?></label></p>
</fieldset>
<span class="akismet-note"><?php esc_html_e( 'To help your site with transparency under privacy laws like the GDPR, Akismet can display a notice to your users under your comment forms. This feature is disabled by default, however, you can turn it on above.', 'akismet' );?></span>
</td>
</tr>
</tbody>
</table>
<div class="akismet-card-actions">
<?php if ( ! Akismet::predefined_api_key() ) { ?>
<div id="delete-action">
<a class="submitdelete deletion" href="<?php echo esc_url( Akismet_Admin::get_page_url( 'delete_key' ) ); ?>"><?php esc_html_e('Disconnect this account', 'akismet'); ?></a>
</div>
</div>
</div>
<?php } ?>
<?php wp_nonce_field(Akismet_Admin::NONCE) ?>
<div class="akismet-settings__row is-radio">
<div class="akismet-settings__row-text">
<h3 class="akismet-settings__row-title"><?php esc_html_e( 'Privacy', 'akismet' ); ?></h3>
</div>
<div class="akismet-settings__row-input">
<fieldset>
<legend class="screen-reader-text">
<span><?php esc_html_e( 'Akismet privacy notice', 'akismet' ); ?></span>
</legend>
<div>
<label class="akismet-settings__row-input-label" for="akismet_comment_form_privacy_notice_display">
<input type="radio" name="akismet_comment_form_privacy_notice" id="akismet_comment_form_privacy_notice_display" value="display" <?php checked( 'display', get_option( 'akismet_comment_form_privacy_notice' ) ); ?> />
<span class="akismet-settings__row-label-text">
<?php esc_html_e( 'Display a privacy notice under your comment forms.', 'akismet' ); ?>
</span>
</label>
</div>
<div>
<label class="akismet-settings__row-input-label" for="akismet_comment_form_privacy_notice_hide">
<input type="radio" name="akismet_comment_form_privacy_notice" id="akismet_comment_form_privacy_notice_hide" value="hide" <?php echo in_array( get_option( 'akismet_comment_form_privacy_notice' ), array( 'display', 'hide' ) ) ? checked( 'hide', get_option( 'akismet_comment_form_privacy_notice' ), false ) : 'checked="checked"'; ?> />
<span class="akismet-settings__row-label-text">
<?php esc_html_e( 'Do not display privacy notice.', 'akismet' ); ?>
</span>
</label>
</div>
</fieldset>
<div class="akismet-settings__row-note">
<?php esc_html_e( 'To help your site with transparency under privacy laws like the GDPR, Akismet can display a notice to your users under your comment forms.', 'akismet' ); ?>
</div>
</div>
</div>
</div>
<div class="akismet-card-actions">
<?php if ( ! Akismet::predefined_api_key() ) : ?>
<div id="delete-action">
<a class="submitdelete deletion" href="<?php echo esc_url( Akismet_Admin::get_page_url( 'delete_key' ) ); ?>"><?php esc_html_e( 'Disconnect this account', 'akismet' ); ?></a>
</div>
<?php endif; ?>
<?php wp_nonce_field( Akismet_Admin::NONCE ); ?>
<div id="publishing-action">
<input type="hidden" name="action" value="enter-key">
<input type="submit" name="submit" id="submit" class="akismet-button akismet-could-be-primary" value="<?php esc_attr_e('Save Changes', 'akismet');?>">
<input type="submit" name="submit" id="submit" class="akismet-button akismet-could-be-primary" value="<?php esc_attr_e( 'Save changes', 'akismet' ); ?>">
</div>
<div class="clear"></div>
</div>
</form>
</div>
</div>
<?php if ( ! Akismet::predefined_api_key() ) { ?>
<?php if ( ! Akismet::predefined_api_key() ) : ?>
<div class="akismet-card">
<div class="akismet-section-header">
<div class="akismet-section-header__label">
<h2 class="akismet-section-header__label">
<span><?php esc_html_e( 'Account' , 'akismet'); ?></span>
</div>
</h2>
</div>
<div class="inside">
<table cellspacing="0" border="0" class="akismet-settings">
<table class="akismet-account">
<tbody>
<tr>
<th scope="row" align="left"><?php esc_html_e( 'Subscription Type' , 'akismet');?></th>
<td width="5%"/>
<td align="left">
<p><?php echo esc_html( $akismet_user->account_name ); ?></p>
<th scope="row"><?php esc_html_e( 'Subscription type', 'akismet' ); ?></th>
<td>
<?php echo esc_html( $akismet_user->account_name ); ?>
</td>
</tr>
<tr>
<th scope="row" align="left"><?php esc_html_e( 'Status' , 'akismet');?></th>
<td width="5%"/>
<td align="left">
<p><?php
if ( 'cancelled' == $akismet_user->status ) :
esc_html_e( 'Cancelled', 'akismet' );
elseif ( 'suspended' == $akismet_user->status ) :
esc_html_e( 'Suspended', 'akismet' );
elseif ( 'missing' == $akismet_user->status ) :
esc_html_e( 'Missing', 'akismet' );
elseif ( 'no-sub' == $akismet_user->status ) :
esc_html_e( 'No Subscription Found', 'akismet' );
else :
esc_html_e( 'Active', 'akismet' );
endif; ?></p>
<th scope="row"><?php esc_html_e( 'Status', 'akismet' ); ?></th>
<td>
<?php
if ( 'cancelled' == $akismet_user->status ) :
esc_html_e( 'Cancelled', 'akismet' );
elseif ( 'suspended' == $akismet_user->status ) :
esc_html_e( 'Suspended', 'akismet' );
elseif ( 'missing' == $akismet_user->status ) :
esc_html_e( 'Missing', 'akismet' );
elseif ( 'no-sub' == $akismet_user->status ) :
esc_html_e( 'No subscription found', 'akismet' );
else :
esc_html_e( 'Active', 'akismet' );
endif;
?>
</td>
</tr>
<?php if ( $akismet_user->next_billing_date ) : ?>
<tr>
<th scope="row" align="left"><?php esc_html_e( 'Next Billing Date' , 'akismet');?></th>
<td width="5%"/>
<td align="left">
<p><?php echo date( 'F j, Y', $akismet_user->next_billing_date ); ?></p>
<th scope="row"><?php esc_html_e( 'Next billing date', 'akismet' ); ?></th>
<td>
<?php echo esc_html( gmdate( 'F j, Y', $akismet_user->next_billing_date ) ); ?>
</td>
</tr>
<?php endif; ?>
@ -253,7 +297,7 @@
</div>
</div>
</div>
<?php } ?>
<?php endif; ?>
<?php endif;?>
</div>
</div>

View File

@ -7,59 +7,85 @@
<div class="akismet-box">
<?php Akismet::view( 'title' ); ?>
<div class="akismet-jp-connect">
<h3><?php esc_html_e( 'Connect with Jetpack', 'akismet' ); ?></h3><?php
if ( in_array( $akismet_user->status, array( 'no-sub', 'missing' ) ) ) {?>
<p><?php esc_html_e( 'Use your Jetpack connection to set up Akismet.', 'akismet' ); ?></p>
<form name="akismet_activate" id="akismet_activate" action="https://akismet.com/get/" method="post" class="akismet-right" target="_blank">
<input type="hidden" name="passback_url" value="<?php echo esc_url( Akismet_Admin::get_page_url() ); ?>"/>
<input type="hidden" name="blog" value="<?php echo esc_url( get_option( 'home' ) ); ?>"/>
<input type="hidden" name="auto-connect" value="<?php echo esc_attr( $akismet_user->ID ); ?>"/>
<input type="hidden" name="redirect" value="plugin-signup"/>
<input type="submit" class="akismet-button akismet-is-primary" value="<?php esc_attr_e( 'Connect with Jetpack' , 'akismet' ); ?>"/>
</form>
<?php echo get_avatar( $akismet_user->user_email, null, null, null, array( 'class' => 'akismet-jetpack-gravatar' ) ); ?>
<p><?php
/* translators: %s is the WordPress.com username */
echo sprintf( esc_html( __( 'You are connected as %s.', 'akismet' ) ), '<b>' . esc_html( $akismet_user->user_login ) . '</b>' ); ?><br /><span class="akismet-jetpack-email"><?php echo esc_html( $akismet_user->user_email ); ?></span></p>
<h3><?php esc_html_e( 'Connect with Jetpack', 'akismet' ); ?></h3>
<?php if ( in_array( $akismet_user->status, array( 'no-sub', 'missing' ) ) ) { ?>
<p><?php esc_html_e( 'Use your Jetpack connection to set up Akismet.', 'akismet' ); ?></p>
<form name="akismet_activate" id="akismet_activate" action="https://akismet.com/get/" method="post" class="akismet-right" target="_blank">
<input type="hidden" name="passback_url" value="<?php echo esc_url( Akismet_Admin::get_page_url() ); ?>"/>
<input type="hidden" name="blog" value="<?php echo esc_url( get_option( 'home' ) ); ?>"/>
<input type="hidden" name="auto-connect" value="<?php echo esc_attr( $akismet_user->ID ); ?>"/>
<input type="hidden" name="redirect" value="plugin-signup"/>
<input type="submit" class="akismet-button akismet-is-primary" value="<?php esc_attr_e( 'Connect with Jetpack', 'akismet' ); ?>"/>
</form>
<?php echo get_avatar( $akismet_user->user_email, null, null, null, array( 'class' => 'akismet-jetpack-gravatar' ) ); ?>
<p>
<?php
/* translators: %s is the WordPress.com username */
echo sprintf( esc_html( __( 'You are connected as %s.', 'akismet' ) ), '<b>' . esc_html( $akismet_user->user_login ) . '</b>' );
?>
<br />
<span class="akismet-jetpack-email"><?php echo esc_html( $akismet_user->user_email ); ?></span>
</p>
<?php } elseif ( $akismet_user->status == 'cancelled' ) { ?>
<p><?php esc_html_e( 'Use your Jetpack connection to set up Akismet.', 'akismet' ); ?></p>
<form name="akismet_activate" id="akismet_activate" action="https://akismet.com/get/" method="post" class="akismet-right" target="_blank">
<input type="hidden" name="passback_url" value="<?php echo esc_url( Akismet_Admin::get_page_url() ); ?>"/>
<input type="hidden" name="blog" value="<?php echo esc_url( get_option( 'home' ) ); ?>"/>
<input type="hidden" name="user_id" value="<?php echo esc_attr( $akismet_user->ID ); ?>"/>
<input type="hidden" name="redirect" value="upgrade"/>
<input type="submit" class="akismet-button akismet-is-primary" value="<?php esc_attr_e( 'Connect with Jetpack' , 'akismet' ); ?>"/>
</form>
<?php echo get_avatar( $akismet_user->user_email, null, null, null, array( 'class' => 'akismet-jetpack-gravatar' ) ); ?>
<p><?php
/* translators: %s is the WordPress.com email address */
echo esc_html( sprintf( __( 'Your subscription for %s is cancelled.' , 'akismet' ), $akismet_user->user_email ) ); ?><br /><span class="akismet-jetpack-email"><?php echo esc_html( $akismet_user->user_email ); ?></span></p>
<?php } elseif ( $akismet_user->status == 'suspended' ) { ?>
<div class="akismet-right">
<p><a href="https://akismet.com/contact" class="akismet-button akismet-is-primary"><?php esc_html_e( 'Contact Akismet support' , 'akismet' ); ?></a></p>
</div>
<p>
<span class="akismet-alert-text"><?php
<p><?php esc_html_e( 'Use your Jetpack connection to set up Akismet.', 'akismet' ); ?></p>
<form name="akismet_activate" id="akismet_activate" action="https://akismet.com/get/" method="post" class="akismet-right" target="_blank">
<input type="hidden" name="passback_url" value="<?php echo esc_url( Akismet_Admin::get_page_url() ); ?>"/>
<input type="hidden" name="blog" value="<?php echo esc_url( get_option( 'home' ) ); ?>"/>
<input type="hidden" name="user_id" value="<?php echo esc_attr( $akismet_user->ID ); ?>"/>
<input type="hidden" name="redirect" value="upgrade"/>
<input type="submit" class="akismet-button akismet-is-primary" value="<?php esc_attr_e( 'Connect with Jetpack', 'akismet' ); ?>"/>
</form>
<?php echo get_avatar( $akismet_user->user_email, null, null, null, array( 'class' => 'akismet-jetpack-gravatar' ) ); ?>
<p>
<?php
/* translators: %s is the WordPress.com email address */
echo esc_html( sprintf( __( 'Your subscription for %s is suspended.' , 'akismet' ), $akismet_user->user_email ) ); ?></span>
<?php esc_html_e( 'No worries! Get in touch and we&#8217;ll sort this out.', 'akismet' ); ?>
</p>
<?php } else { // ask do they want to use akismet account found using jetpack wpcom connection ?>
<p><?php esc_html_e( 'Use your Jetpack connection to set up Akismet.', 'akismet' ); ?></p>
<form name="akismet_use_wpcom_key" action="<?php echo esc_url( Akismet_Admin::get_page_url() ); ?>" method="post" id="akismet-activate" class="akismet-right">
<input type="hidden" name="key" value="<?php echo esc_attr( $akismet_user->api_key );?>"/>
<input type="hidden" name="action" value="enter-key">
<?php wp_nonce_field( Akismet_Admin::NONCE ) ?>
<input type="submit" class="akismet-button akismet-is-primary" value="<?php esc_attr_e( 'Connect with Jetpack' , 'akismet' ); ?>"/>
</form>
<?php echo get_avatar( $akismet_user->user_email, null, null, null, array( 'class' => 'akismet-jetpack-gravatar' ) ); ?>
<p><?php
/* translators: %s is the WordPress.com username */
echo sprintf( esc_html( __( 'You are connected as %s.', 'akismet' ) ), '<b>' . esc_html( $akismet_user->user_login ) . '</b>' ); ?><br /><span class="akismet-jetpack-email"><?php echo esc_html( $akismet_user->user_email ); ?></span></p>
<?php } ?>
echo esc_html( sprintf( __( 'Your subscription for %s is cancelled.', 'akismet' ), $akismet_user->user_email ) );
?>
<br />
<span class="akismet-jetpack-email"><?php echo esc_html( $akismet_user->user_email ); ?></span>
</p>
<?php } elseif ( $akismet_user->status == 'suspended' ) { ?>
<div class="akismet-right">
<p><a href="https://akismet.com/contact" class="akismet-button akismet-is-primary"><?php esc_html_e( 'Contact Akismet support', 'akismet' ); ?></a></p>
</div>
<p>
<span class="akismet-alert-text">
<?php
/* translators: %s is the WordPress.com email address */
echo esc_html( sprintf( __( 'Your subscription for %s is suspended.', 'akismet' ), $akismet_user->user_email ) );
?>
</span>
<?php esc_html_e( 'No worries! Get in touch and we&#8217;ll sort this out.', 'akismet' ); ?>
</p>
<?php } else { // ask do they want to use akismet account found using jetpack wpcom connection ?>
<p><?php esc_html_e( 'Use your Jetpack connection to set up Akismet.', 'akismet' ); ?></p>
<form name="akismet_use_wpcom_key" action="<?php echo esc_url( Akismet_Admin::get_page_url() ); ?>" method="post" id="akismet-activate" class="akismet-right">
<input type="hidden" name="key" value="<?php echo esc_attr( $akismet_user->api_key ); ?>"/>
<input type="hidden" name="action" value="enter-key">
<?php wp_nonce_field( Akismet_Admin::NONCE ); ?>
<input type="submit" class="akismet-button akismet-is-primary" value="<?php esc_attr_e( 'Connect with Jetpack', 'akismet' ); ?>"/>
</form>
<?php echo get_avatar( $akismet_user->user_email, null, null, null, array( 'class' => 'akismet-jetpack-gravatar' ) ); ?>
<p>
<?php
/* translators: %s is the WordPress.com username */
echo sprintf( esc_html( __( 'You are connected as %s.', 'akismet' ) ), '<b>' . esc_html( $akismet_user->user_login ) . '</b>' );
?>
<br />
<span class="akismet-jetpack-email"><?php echo esc_html( $akismet_user->user_email ); ?></span>
</p>
<?php } ?>
</div>
<div class="akismet-ak-connect">
<?php Akismet::view( 'setup' );?>
<?php Akismet::view( 'setup' ); ?>
</div>
<div class="centered akismet-toggles">
<a href="#" class="toggle-jp-connect"><?php esc_html_e( 'Connect with Jetpack', 'akismet' ); ?></a>
@ -68,5 +94,5 @@
</div>
<br/>
<div class="akismet-box">
<?php Akismet::view( 'enter' );?>
</div>
<?php Akismet::view( 'enter' ); ?>
</div>

View File

@ -1,13 +1,14 @@
<div class="akismet-enter-api-key-box centered">
<a href="#"><?php esc_html_e( 'Manually enter an API key', 'akismet' ); ?></a>
<div class="enter-api-key">
<button class="akismet-enter-api-key-box__reveal"><?php esc_html_e( 'Manually enter an API key', 'akismet' ); ?></button>
<div class="akismet-enter-api-key-box__form-wrapper">
<form action="<?php echo esc_url( Akismet_Admin::get_page_url() ); ?>" method="post">
<?php wp_nonce_field( Akismet_Admin::NONCE ) ?>
<?php wp_nonce_field( Akismet_Admin::NONCE ); ?>
<input type="hidden" name="action" value="enter-key">
<p style="width: 100%; display: flex; flex-wrap: nowrap; box-sizing: border-box;">
<input id="key" name="key" type="text" size="15" value="" placeholder="<?php esc_attr_e( 'Enter your API key' , 'akismet' ); ?>" class="regular-text code" style="flex-grow: 1; margin-right: 1rem;">
<input type="submit" name="submit" id="submit" class="akismet-button" value="<?php esc_attr_e( 'Connect with API key', 'akismet' );?>">
</p>
<h3 class="akismet-enter-api-key-box__header" id="akismet-enter-api-key-box__header"><?php esc_html_e( 'Enter your API key', 'akismet' ); ?></h3>
<div class="akismet-enter-api-key-box__input-wrapper">
<input id="key" name="key" type="text" size="15" value="" placeholder="<?php esc_attr_e( 'API key', 'akismet' ); ?>" class="akismet-enter-api-key-box__key-input regular-text code" aria-labelledby="akismet-enter-api-key-box__header">
<input type="submit" name="submit" id="submit" class="akismet-button" value="<?php esc_attr_e( 'Connect with API key', 'akismet' ); ?>">
</div>
</form>
</div>
</div>
</div>

View File

@ -2,11 +2,17 @@
//phpcs:disable VariableAnalysis
// There are "undefined" variables here because they're defined in the code that includes this file as a template.
$submit_classes_attr = 'akismet-button';
if ( isset( $classes ) && ( is_countable( $classes ) ? count( $classes ) : 0 ) > 0 ) {
$submit_classes_attr = implode( ' ', $classes );
}
?>
<form name="akismet_activate" action="https://akismet.com/get/" method="POST" target="_blank">
<input type="hidden" name="passback_url" value="<?php echo esc_url( Akismet_Admin::get_page_url() ); ?>"/>
<input type="hidden" name="blog" value="<?php echo esc_url( get_option( 'home' ) ); ?>"/>
<input type="hidden" name="redirect" value="<?php echo isset( $redirect ) ? $redirect : 'plugin-signup'; ?>"/>
<button type="submit" class="<?php echo isset( $classes ) && count( $classes ) > 0 ? esc_attr( implode( ' ', $classes ) ) : 'akismet-button'; ?>" value="<?php echo esc_attr( $text ); ?>"><?php echo esc_attr( $text ) . '<span class="screen-reader-text">' . esc_html__( '(opens in a new tab)', 'akismet' ) . '</span>'; ?></button>
<button type="submit" class="<?php echo esc_attr( $submit_classes_attr ); ?>" value="<?php echo esc_attr( $text ); ?>"><?php echo esc_attr( $text ) . '<span class="screen-reader-text">' . esc_html__( '(opens in a new tab)', 'akismet' ) . '</span>'; ?></button>
</form>

View File

@ -0,0 +1,13 @@
<?php
//phpcs:disable VariableAnalysis
// There are "undefined" variables here because they're defined in the code that includes this file as a template.
?>
<div class="akismet-masthead__logo-container">
<?php if ( isset( $include_logo_link ) && $include_logo_link === true ) : ?>
<a href="<?php echo esc_url( Akismet_Admin::get_page_url() ); ?>" class="akismet-masthead__logo-link">
<?php endif; ?>
<img class="akismet-masthead__logo" src="<?php echo esc_url( plugins_url( '../_inc/img/akismet-refresh-logo@2x.png', __FILE__ ) ); ?>" srcset="<?php echo esc_url( plugins_url( '../_inc/img/akismet-refresh-logo.svg', __FILE__ ) ); ?>" alt="Akismet logo" />
<?php if ( isset( $include_logo_link ) && $include_logo_link === true ) : ?>
</a>
<?php endif; ?>
</div>

View File

@ -1,10 +1,20 @@
<?php
//phpcs:disable VariableAnalysis
// There are "undefined" variables here because they're defined in the code that includes this file as a template.
$kses_allow_link = array(
'a' => array(
'href' => true,
'target' => true,
),
);
$kses_allow_strong = array( 'strong' => true );
/*
* Some notices (plugin, spam-check, spam-check-cron-disabled, alert and usage-limit) are shown elsewhere in wp-admin,
* so look different to the standard notices.
*/
?>
<?php if ( $type == 'plugin' ) : ?>
<?php if ( $type === 'plugin' ) : ?>
<div class="updated" id="akismet_setup_prompt">
<form name="akismet_activate" action="<?php echo esc_url( Akismet_Admin::get_page_url() ); ?>" method="POST">
<div class="akismet_activate">
@ -14,158 +24,220 @@
<input type="submit" class="aa_button" value="<?php esc_attr_e( 'Set up your Akismet account', 'akismet' ); ?>" />
</div>
</div>
<div class="aa_description"><?php _e('<strong>Almost done</strong> - configure Akismet and say goodbye to spam', 'akismet');?></div>
<div class="aa_description">
<?php
echo wp_kses(
__( '<strong>Almost done</strong> - configure Akismet and say goodbye to spam', 'akismet' ),
$kses_allow_strong
);
?>
</div>
</div>
</form>
</div>
<?php elseif ( $type == 'spam-check' ) : ?>
<?php elseif ( $type === 'spam-check' ) : ?>
<div class="notice notice-warning">
<p><strong><?php esc_html_e( 'Akismet has detected a problem.', 'akismet' );?></strong></p>
<p><strong><?php esc_html_e( 'Akismet has detected a problem.', 'akismet' ); ?></strong></p>
<p><?php esc_html_e( 'Some comments have not yet been checked for spam by Akismet. They have been temporarily held for moderation and will automatically be rechecked later.', 'akismet' ); ?></p>
<?php if ( $link_text ) { ?>
<p><?php echo $link_text; ?></p>
<?php } ?>
<?php if ( $link_text ) : ?>
<p><?php echo wp_kses( $link_text, $kses_allow_link ); ?></p>
<?php endif; ?>
</div>
<?php elseif ( $type == 'spam-check-cron-disabled' ) : ?>
<?php elseif ( $type === 'spam-check-cron-disabled' ) : ?>
<div class="notice notice-warning">
<p><strong><?php esc_html_e( 'Akismet has detected a problem.', 'akismet' ); ?></strong></p>
<p><?php esc_html_e( 'WP-Cron has been disabled using the DISABLE_WP_CRON constant. Comment rechecks may not work properly.', 'akismet' ); ?></p>
</div>
<?php elseif ( $type == 'alert' ) : ?>
<div class='error'>
<p><strong><?php printf( esc_html__( 'Akismet Error Code: %s', 'akismet' ), $code ); ?></strong></p>
<?php elseif ( $type === 'alert' ) : ?>
<div class="error">
<?php /* translators: The placeholder is an error code returned by Akismet. */ ?>
<p><strong><?php printf( esc_html__( 'Akismet error code: %s', 'akismet' ), esc_html( $code ) ); ?></strong></p>
<p><?php echo esc_html( $msg ); ?></p>
<p><?php
/* translators: the placeholder is a clickable URL that leads to more information regarding an error code. */
printf( esc_html__( 'For more information: %s' , 'akismet'), '<a href="https://akismet.com/errors/' . $code . '">https://akismet.com/errors/' . $code . '</a>' );
?>
</p>
</div>
<?php elseif ( $type == 'notice' ) : ?>
<div class="akismet-alert akismet-critical">
<h3 class="akismet-key-status failed"><?php echo $notice_header; ?></h3>
<p class="akismet-description">
<?php echo $notice_text; ?>
</p>
</div>
<?php elseif ( $type == 'missing-functions' ) : ?>
<div class="akismet-alert akismet-critical">
<h3 class="akismet-key-status failed"><?php esc_html_e('Network functions are disabled.', 'akismet'); ?></h3>
<p class="akismet-description"><?php printf( __('Your web host or server administrator has disabled PHP&#8217;s <code>gethostbynamel</code> function. <strong>Akismet cannot work correctly until this is fixed.</strong> Please contact your web host or firewall administrator and give them <a href="%s" target="_blank">this information about Akismet&#8217;s system requirements</a>.', 'akismet'), 'https://blog.akismet.com/akismet-hosting-faq/'); ?></p>
</div>
<?php elseif ( $type == 'servers-be-down' ) : ?>
<div class="akismet-alert akismet-critical">
<h3 class="akismet-key-status failed"><?php esc_html_e("Your site can&#8217;t connect to the Akismet servers.", 'akismet'); ?></h3>
<p class="akismet-description"><?php printf( __('Your firewall may be blocking Akismet from connecting to its API. Please contact your host and refer to <a href="%s" target="_blank">our guide about firewalls</a>.', 'akismet'), 'https://blog.akismet.com/akismet-hosting-faq/'); ?></p>
</div>
<?php elseif ( $type == 'active-dunning' ) : ?>
<div class="akismet-alert akismet-critical">
<h3 class="akismet-key-status"><?php esc_html_e("Please update your payment information.", 'akismet'); ?></h3>
<p class="akismet-description"><?php printf( __('We cannot process your payment. Please <a href="%s" target="_blank">update your payment details</a>.', 'akismet'), 'https://akismet.com/account/'); ?></p>
</div>
<?php elseif ( $type == 'cancelled' ) : ?>
<div class="akismet-alert akismet-critical">
<h3 class="akismet-key-status"><?php esc_html_e("Your Akismet plan has been cancelled.", 'akismet'); ?></h3>
<p class="akismet-description"><?php printf( __('Please visit your <a href="%s" target="_blank">Akismet account page</a> to reactivate your subscription.', 'akismet'), 'https://akismet.com/account/'); ?></p>
</div>
<?php elseif ( $type == 'suspended' ) : ?>
<div class="akismet-alert akismet-critical">
<h3 class="akismet-key-status failed"><?php esc_html_e("Your Akismet subscription is suspended.", 'akismet'); ?></h3>
<p class="akismet-description"><?php printf( __('Please contact <a href="%s" target="_blank">Akismet support</a> for assistance.', 'akismet'), 'https://akismet.com/contact/'); ?></p>
</div>
<?php elseif ( $type == 'active-notice' && $time_saved ) : ?>
<div class="akismet-alert akismet-active">
<h3 class="akismet-key-status"><?php echo esc_html( $time_saved ); ?></h3>
<p class="akismet-description"><?php printf( __('You can help us fight spam and upgrade your account by <a href="%s" target="_blank">contributing a token amount</a>.', 'akismet'), 'https://akismet.com/account/upgrade/'); ?></p>
</div>
<?php elseif ( $type == 'missing' ) : ?>
<div class="akismet-alert akismet-critical">
<h3 class="akismet-key-status failed"><?php esc_html_e( 'There is a problem with your API key.', 'akismet'); ?></h3>
<p class="akismet-description"><?php printf( __('Please contact <a href="%s" target="_blank">Akismet support</a> for assistance.', 'akismet'), 'https://akismet.com/contact/'); ?></p>
</div>
<?php elseif ( $type == 'no-sub' ) : ?>
<div class="akismet-alert akismet-critical">
<h3 class="akismet-key-status failed"><?php esc_html_e( 'You don&#8217;t have an Akismet plan.', 'akismet'); ?></h3>
<p class="akismet-description">
<?php printf( __( 'In 2012, Akismet began using subscription plans for all accounts (even free ones). A plan has not been assigned to your account, and we&#8217;d appreciate it if you&#8217;d <a href="%s" target="_blank">sign into your account</a> and choose one.', 'akismet'), 'https://akismet.com/account/upgrade/' ); ?>
<br /><br />
<?php printf( __( 'Please <a href="%s" target="_blank">contact our support team</a> with any questions.', 'akismet' ), 'https://akismet.com/contact/' ); ?>
</p>
</div>
<?php elseif ( $type == 'new-key-valid' ) :
global $wpdb;
$check_pending_link = false;
$at_least_one_comment_in_moderation = !! $wpdb->get_var( "SELECT comment_ID FROM {$wpdb->comments} WHERE comment_approved = '0' LIMIT 1" );
if ( $at_least_one_comment_in_moderation) {
$check_pending_link = 'edit-comments.php?akismet_recheck=' . wp_create_nonce( 'akismet_recheck' );
}
?>
<div class="akismet-alert akismet-active">
<h3 class="akismet-key-status"><?php esc_html_e( 'Akismet is now protecting your site from spam. Happy blogging!', 'akismet' ); ?></h3>
<?php if ( $check_pending_link ) { ?>
<p class="akismet-description"><?php printf( __( 'Would you like to <a href="%s">check pending comments</a>?', 'akismet' ), esc_url( $check_pending_link ) ); ?></p>
<?php } ?>
</div>
<?php elseif ( $type == 'new-key-invalid' ) : ?>
<div class="akismet-alert akismet-critical">
<h3 class="akismet-key-status"><?php esc_html_e( 'The key you entered is invalid. Please double-check it.' , 'akismet'); ?></h3>
</div>
<?php elseif ( $type == 'existing-key-invalid' ) : ?>
<div class="akismet-alert akismet-critical">
<h3 class="akismet-key-status"><?php echo esc_html( __( 'Your API key is no longer valid.', 'akismet' ) ); ?></h3>
<p class="akismet-description">
<p>
<?php
echo wp_kses(
sprintf(
/* translators: The placeholder is a URL. */
__( 'Please enter a new key or <a href="%s" target="_blank">contact Akismet support</a>.', 'akismet' ),
'https://akismet.com/contact/'
),
array(
'a' => array(
'href' => true,
'target' => true,
),
)
);
/* translators: the placeholder is a clickable URL that leads to more information regarding an error code. */
printf( esc_html__( 'For more information: %s', 'akismet' ), '<a href="https://akismet.com/errors/' . esc_attr( $code ) . '">https://akismet.com/errors/' . esc_attr( $code ) . '</a>' );
?>
</p>
</div>
<?php elseif ( $type == 'new-key-failed' ) : ?>
<div class="akismet-alert akismet-critical">
<h3 class="akismet-key-status"><?php esc_html_e( 'The API key you entered could not be verified.' , 'akismet'); ?></h3>
<p class="akismet-description">
<?php
<?php elseif ( $type === 'notice' ) : ?>
<div class="akismet-alert is-bad">
<h3 class="akismet-alert__heading"><?php echo wp_kses( $notice_header, Akismet_Admin::get_notice_kses_allowed_elements() ); ?></h3>
<p>
<?php echo wp_kses( $notice_text, Akismet_Admin::get_notice_kses_allowed_elements() ); ?>
</p>
</div>
<?php elseif ( $type === 'missing-functions' ) : ?>
<div class="akismet-alert is-bad">
<h3 class="akismet-alert__heading"><?php esc_html_e( 'Network functions are disabled.', 'akismet' ); ?></h3>
<p>
<?php
/* translators: The placeholder is a URL. */
echo wp_kses( sprintf( __( 'Your web host or server administrator has disabled PHP&#8217;s <code>gethostbynamel</code> function. <strong>Akismet cannot work correctly until this is fixed.</strong> Please contact your web host or firewall administrator and give them <a href="%s" target="_blank">this information about Akismet&#8217;s system requirements</a>.', 'akismet' ), esc_url( 'https://akismet.com/akismet-hosting-faq/' ) ), array_merge( $kses_allow_link, $kses_allow_strong, array( 'code' => true ) ) );
?>
</p>
</div>
<?php elseif ( $type === 'servers-be-down' ) : ?>
<div class="akismet-alert is-bad">
<h3 class="akismet-alert__heading"><?php esc_html_e( 'Your site can&#8217;t connect to the Akismet servers.', 'akismet' ); ?></h3>
<p>
<?php
/* translators: The placeholder is a URL. */
echo wp_kses( sprintf( __( 'Your firewall may be blocking Akismet from connecting to its API. Please contact your host and refer to <a href="%s" target="_blank">our guide about firewalls</a>.', 'akismet' ), esc_url( 'https://akismet.com/akismet-hosting-faq/' ) ), $kses_allow_link );
?>
</p>
</div>
<?php elseif ( $type === 'active-dunning' ) : ?>
<div class="akismet-alert is-bad">
<h3 class="akismet-alert__heading"><?php esc_html_e( 'Please update your payment information.', 'akismet' ); ?></h3>
<p>
<?php
/* translators: The placeholder is a URL. */
echo wp_kses( sprintf( __( 'We cannot process your payment. Please <a href="%s" target="_blank">update your payment details</a>.', 'akismet' ), esc_url( 'https://akismet.com/account/' ) ), $kses_allow_link );
?>
</p>
</div>
<?php elseif ( $type === 'cancelled' ) : ?>
<div class="akismet-alert is-bad">
<h3 class="akismet-alert__heading"><?php esc_html_e( 'Your Akismet plan has been cancelled.', 'akismet' ); ?></h3>
<p>
<?php
/* translators: The placeholder is a URL. */
echo wp_kses( sprintf( __( 'Please visit your <a href="%s" target="_blank">Akismet account page</a> to reactivate your subscription.', 'akismet' ), esc_url( 'https://akismet.com/account/' ) ), $kses_allow_link );
?>
</p>
</div>
<?php elseif ( $type === 'suspended' ) : ?>
<div class="akismet-alert is-bad">
<h3 class="akismet-alert__heading"><?php esc_html_e( 'Your Akismet subscription is suspended.', 'akismet' ); ?></h3>
<p>
<?php
/* translators: The placeholder is a URL. */
echo wp_kses( sprintf( __( 'Please contact <a href="%s" target="_blank">Akismet support</a> for assistance.', 'akismet' ), esc_url( 'https://akismet.com/contact/' ) ), $kses_allow_link );
?>
</p>
</div>
<?php elseif ( $type === 'active-notice' && $time_saved ) : ?>
<div class="akismet-alert is-neutral">
<h3 class="akismet-alert__heading"><?php echo esc_html( $time_saved ); ?></h3>
<p>
<?php
/* translators: the placeholder is a clickable URL to the Akismet account upgrade page. */
echo wp_kses( sprintf( __( 'You can help us fight spam and upgrade your account by <a href="%s" target="_blank">contributing a token amount</a>.', 'akismet' ), esc_url( 'https://akismet.com/pricing' ) ), $kses_allow_link );
?>
</p>
</div>
<?php elseif ( $type === 'missing' ) : ?>
<div class="akismet-alert is-bad">
<h3 class="akismet-alert__heading"><?php esc_html_e( 'There is a problem with your API key.', 'akismet' ); ?></h3>
<p>
<?php
/* translators: The placeholder is a URL to the Akismet contact form. */
echo wp_kses( sprintf( __( 'Please contact <a href="%s" target="_blank">Akismet support</a> for assistance.', 'akismet' ), esc_url( 'https://akismet.com/contact/' ) ), $kses_allow_link );
?>
</p>
</div>
<?php elseif ( $type === 'no-sub' ) : ?>
<div class="akismet-alert is-bad">
<h3 class="akismet-alert__heading"><?php esc_html_e( 'You don&#8217;t have an Akismet plan.', 'akismet' ); ?></h3>
<p>
<?php
/* translators: the placeholder is a clickable URL to the Akismet account upgrade page. */
echo wp_kses( sprintf( __( 'In 2012, Akismet began using subscription plans for all accounts (even free ones). A plan has not been assigned to your account, and we&#8217;d appreciate it if you&#8217;d <a href="%s" target="_blank">sign into your account</a> and choose one.', 'akismet' ), esc_url( 'https://akismet.com/pricing' ) ), $kses_allow_link );
?>
<br /><br />
<?php
/* translators: The placeholder is a URL to the Akismet contact form. */
echo wp_kses( sprintf( __( 'Please <a href="%s" target="_blank">contact our support team</a> with any questions.', 'akismet' ), esc_url( 'https://akismet.com/contact/' ) ), $kses_allow_link );
?>
</p>
</div>
<?php elseif ( $type === 'new-key-valid' ) : ?>
<?php
global $wpdb;
$check_pending_link = false;
$at_least_one_comment_in_moderation = ! ! $wpdb->get_var( "SELECT comment_ID FROM {$wpdb->comments} WHERE comment_approved = '0' LIMIT 1" );
if ( $at_least_one_comment_in_moderation ) {
$check_pending_link = 'edit-comments.php?akismet_recheck=' . wp_create_nonce( 'akismet_recheck' );
}
?>
<div class="akismet-alert is-good">
<p><?php esc_html_e( 'Akismet is now protecting your site from spam. Happy blogging!', 'akismet' ); ?></p>
<?php if ( $check_pending_link ) : ?>
<p>
<?php
echo wp_kses(
sprintf(
/* translators: The placeholder is a URL for checking pending comments. */
__( 'Would you like to <a href="%s">check pending comments</a>?', 'akismet' ),
esc_url( $check_pending_link )
),
$kses_allow_link
);
?>
</p>
<?php endif; ?>
</div>
<?php elseif ( $type === 'new-key-invalid' ) : ?>
<div class="akismet-alert is-bad">
<p><?php esc_html_e( 'The key you entered is invalid. Please double-check it.', 'akismet' ); ?></p>
</div>
<?php elseif ( $type === 'existing-key-invalid' ) : ?>
<div class="akismet-alert is-bad">
<h3 class="akismet-alert__heading"><?php echo esc_html( __( 'Your API key is no longer valid.', 'akismet' ) ); ?></h3>
<p>
<?php
echo wp_kses(
sprintf(
/* translators: The placeholder is a URL to the Akismet contact form. */
__( 'Please enter a new key or <a href="%s" target="_blank">contact Akismet support</a>.', 'akismet' ),
'https://akismet.com/contact/'
),
$kses_allow_link
);
?>
</p>
</div>
<?php elseif ( $type === 'new-key-failed' ) : ?>
<div class="akismet-alert is-bad">
<h3 class="akismet-alert__heading"><?php esc_html_e( 'The API key you entered could not be verified.', 'akismet' ); ?></h3>
<p>
<?php
echo wp_kses(
sprintf(
/* translators: The placeholder is a URL. */
__( 'The connection to akismet.com could not be established. Please refer to <a href="%s" target="_blank">our guide about firewalls</a> and check your server configuration.', 'akismet' ),
'https://blog.akismet.com/akismet-hosting-faq/'
),
array(
'a' => array(
'href' => true,
'target' => true,
),
)
$kses_allow_link
);
?>
</p>
</div>
<?php elseif ( $type == 'usage-limit' && isset( Akismet::$limit_notices[ $code ] ) ) : ?>
<?php elseif ( $type === 'usage-limit' && isset( Akismet::$limit_notices[ $code ] ) ) : ?>
<div class="error akismet-usage-limit-alert">
<div class="akismet-usage-limit-logo">
<img src="<?php echo esc_url( plugins_url( '../_inc/img/logo-a-2x.png', __FILE__ ) ); ?>" alt="Akismet" />
<img src="<?php echo esc_url( plugins_url( '../_inc/img/logo-a-2x.png', __FILE__ ) ); ?>" alt="Akismet logo" />
</div>
<div class="akismet-usage-limit-text">
<h3>
@ -199,7 +271,7 @@
number_format( $usage_limit )
)
);
echo '&nbsp;';
echo '<a href="https://docs.akismet.com/akismet-api-usage-limits/" target="_blank">';
echo esc_html( __( 'Learn more about usage limits.', 'akismet' ) );
echo '</a>';
@ -207,7 +279,7 @@
break;
case 'SECOND_MONTH_OVER_LIMIT':
echo esc_html( __( 'Your Akismet usage has been over your plan&#8217;s limit for two consecutive months. Next month, we will restrict your account after you reach the limit. Please consider upgrading your plan.', 'akismet' ) );
echo '&nbsp;';
echo '<a href="https://docs.akismet.com/akismet-api-usage-limits/" target="_blank">';
echo esc_html( __( 'Learn more about usage limits.', 'akismet' ) );
echo '</a>';
@ -215,7 +287,7 @@
break;
case 'THIRD_MONTH_APPROACHING_LIMIT':
echo esc_html( __( 'Your Akismet usage is nearing your plan&#8217;s limit for the third consecutive month. We will restrict your account after you reach the limit. Upgrade your plan so Akismet can continue blocking spam.', 'akismet' ) );
echo '&nbsp;';
echo '<a href="https://docs.akismet.com/akismet-api-usage-limits/" target="_blank">';
echo esc_html( __( 'Learn more about usage limits.', 'akismet' ) );
echo '</a>';
@ -224,12 +296,13 @@
case 'THIRD_MONTH_OVER_LIMIT':
case 'FOUR_PLUS_MONTHS_OVER_LIMIT':
echo esc_html( __( 'Your Akismet usage has been over your plan&#8217;s limit for three consecutive months. We have restricted your account for the rest of the month. Upgrade your plan so Akismet can continue blocking spam.', 'akismet' ) );
echo '&nbsp;';
echo '<a href="https://docs.akismet.com/akismet-api-usage-limits/" target="_blank">';
echo esc_html( __( 'Learn more about usage limits.', 'akismet' ) );
echo '</a>';
break;
default:
}
?>
@ -240,7 +313,7 @@
<?php
// If only a qty upgrade is required, show a more generic message.
if ( ! empty( $upgrade_type ) && 'qty' === $upgrade_type ) {
esc_html_e( 'Upgrade your Subscription Level', 'akismet' );
esc_html_e( 'Upgrade your subscription level', 'akismet' );
} else {
echo esc_html(
sprintf(

View File

@ -7,9 +7,7 @@
<div id="akismet-plugin-container">
<div class="akismet-masthead">
<div class="akismet-masthead__inside-container">
<div class="akismet-masthead__logo-container">
<img class="akismet-masthead__logo" src="<?php echo esc_url( plugins_url( '../_inc/img/logo-full-2x.png', __FILE__ ) ); ?>" alt="Akismet" />
</div>
<?php Akismet::view( 'logo' ); ?>
</div>
</div>
<div class="akismet-lower">

View File

@ -1,11 +1,12 @@
<div id="akismet-plugin-container">
<div class="akismet-masthead">
<div class="akismet-masthead__inside-container">
<a href="<?php echo esc_url( Akismet_Admin::get_page_url() ); ?>" class="akismet-right"><?php esc_html_e( 'Anti-Spam Settings', 'akismet' ); ?></a>
<div class="akismet-masthead__logo-container">
<img class="akismet-masthead__logo" src="<?php echo esc_url( plugins_url( '../_inc/img/logo-full-2x.png', __FILE__ ) ); ?>" alt="Akismet" />
<?php Akismet::view( 'logo', array( 'include_logo_link' => true ) ); ?>
<div class="akismet-masthead__back-link-container">
<a class="akismet-masthead__back-link" href="<?php echo esc_url( Akismet_Admin::get_page_url() ); ?>"><?php esc_html_e( 'Back to settings', 'akismet' ); ?></a>
</div>
</div>
</div>
<iframe src="<?php echo esc_url( sprintf( 'https://tools.akismet.com/1.0/user-stats.php?blog=%s&token=%s&locale=%s', urlencode( get_option( 'home' ) ), urlencode( Akismet::get_access_token() ), esc_attr( get_locale() ) ) ); ?>" width="100%" height="2500px" frameborder="0"></iframe>
<?php /* name attribute on iframe is used as a cache-buster here to force Firefox to load the new style charts: https://bugzilla.mozilla.org/show_bug.cgi?id=356558 */ ?>
<iframe id="stats-iframe" src="<?php echo esc_url( sprintf( 'https://tools.akismet.com/1.0/user-stats.php?blog=%s&token=%s&locale=%s&is_redecorated=1', urlencode( get_option( 'home' ) ), urlencode( Akismet::get_access_token() ), esc_attr( get_locale() ) ) ); ?>" name="<?php echo esc_attr( 'user-stats- ' . filemtime( __FILE__ ) ); ?>" width="100%" height="2500px" frameborder="0" title="<?php echo esc_attr__( 'Akismet detailed stats' ); ?>"></iframe>
</div>

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1 @@
(window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[]).push([[33],{650:function(e,t,r){"use strict";r.r(t);var l=r(2);function n(){return(n=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var l in r)Object.prototype.hasOwnProperty.call(r,l)&&(e[l]=r[l])}return e}).apply(this,arguments)}var i=l.createElement("g",{filter:"url(#ghost-card-green_svg__filter0_d_4824_80823)"},l.createElement("rect",{width:165,height:90,rx:11,fill:"#fff"}),l.createElement("rect",{x:.5,y:.5,width:164,height:89,rx:10.5,stroke:"#EBEEF0"})),a=l.createElement("rect",{x:16,y:16,width:64,height:8,rx:4,fill:"#EBEEF0"}),o=l.createElement("path",{d:"M16 43c0-5.523 4.477-10 10-10h30c5.523 0 10 4.477 10 10s-4.477 10-10 10H26c-5.523 0-10-4.477-10-10z",fill:"#B8E6CA"}),c=l.createElement("rect",{x:16,y:68,width:133,height:8,rx:4,fill:"#EBEEF0"}),f=l.createElement("path",{d:"M25 46.667l6.593-6.594m0 0L26.392 40m5.201.073l.074 5.202",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),h=l.createElement("rect",{x:38,y:40,width:20,height:6,rx:2,fill:"#fff"}),s=l.createElement("defs",null,l.createElement("filter",{id:"ghost-card-green_svg__filter0_d_4824_80823",x:0,y:0,width:169,height:95,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},l.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),l.createElement("feColorMatrix",{in:"SourceAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),l.createElement("feOffset",{dx:4,dy:5}),l.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),l.createElement("feColorMatrix",{values:"0 0 0 0 0.921569 0 0 0 0 0.933333 0 0 0 0 0.941176 0 0 0 1 0"}),l.createElement("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_4824_80823"}),l.createElement("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_4824_80823",result:"shape"})));t.default=function SvgGhostCardGreen(e){return l.createElement("svg",n({viewBox:"0 0 169 95",fill:"none"},e),i,a,o,c,f,h,s)}}}]);

View File

@ -0,0 +1 @@
(window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[]).push([[34],{651:function(e,t,r){"use strict";r.r(t);var l=r(2);function i(){return(i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var l in r)Object.prototype.hasOwnProperty.call(r,l)&&(e[l]=r[l])}return e}).apply(this,arguments)}var n=l.createElement("g",{filter:"url(#ghost-card-red_svg__filter0_d_4824_80809)"},l.createElement("rect",{width:165,height:90,rx:11,fill:"#fff"}),l.createElement("rect",{x:.5,y:.5,width:164,height:89,rx:10.5,stroke:"#EBEEF0"})),a=l.createElement("rect",{x:16,y:16,width:25,height:8,rx:4,fill:"#EBEEF0"}),o=l.createElement("rect",{x:16,y:33,width:50,height:20,rx:10,fill:"#FFDED3"}),c=l.createElement("rect",{x:16,y:68,width:133,height:8,rx:4,fill:"#EBEEF0"}),f=l.createElement("path",{d:"M24.997 40l6.594 6.593m0 0l.073-5.201m-.073 5.201l-5.202.074",stroke:"#fff",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),h=l.createElement("rect",{x:38,y:40,width:20,height:6,rx:2,fill:"#fff"}),d=l.createElement("defs",null,l.createElement("filter",{id:"ghost-card-red_svg__filter0_d_4824_80809",x:0,y:0,width:169,height:95,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},l.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),l.createElement("feColorMatrix",{in:"SourceAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),l.createElement("feOffset",{dx:4,dy:5}),l.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),l.createElement("feColorMatrix",{values:"0 0 0 0 0.921569 0 0 0 0 0.933333 0 0 0 0 0.941176 0 0 0 1 0"}),l.createElement("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_4824_80809"}),l.createElement("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_4824_80809",result:"shape"})));t.default=function SvgGhostCardRed(e){return l.createElement("svg",i({viewBox:"0 0 169 95",fill:"none"},e),n,a,o,c,f,h,d)}}}]);

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1 @@
(window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[]).push([[24],{1010:function(t,n,e){"use strict";e.r(n),function(t){var n=e(5),i=e.n(n),s=e(15),o=e.n(s);function a(){return(a=o()(i.a.mark((function n(){return i.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(void 0!==t.IntersectionObserver){n.next=3;break}return n.next=3,e.e(35).then(e.t.bind(null,1043,7));case 3:case"end":return n.stop()}}),n)})))).apply(this,arguments)}e.p="".concat(t._googlesitekitBaseData.assetsURL,"js/"),function(){a.apply(this,arguments)}()}.call(this,e(26))}},[[1010,1,0]]]);

View File

@ -1 +0,0 @@
(window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[]).push([[24],{950:function(t,n,e){"use strict";e.r(n),function(t){var n=e(5),i=e.n(n),s=e(17),o=e.n(s);function a(){return(a=o()(i.a.mark((function n(){return i.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(void 0!==t.IntersectionObserver){n.next=3;break}return n.next=3,e.e(33).then(e.t.bind(null,980,7));case 3:case"end":return n.stop()}}),n)})))).apply(this,arguments)}e.p="".concat(t._googlesitekitBaseData.assetsURL,"js/"),function(){a.apply(this,arguments)}()}.call(this,e(25))}},[[950,1,0]]]);

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1 @@
!function(e){function r(r){for(var t,a,u=r[0],i=r[1],p=r[2],f=0,l=[];f<u.length;f++)a=u[f],Object.prototype.hasOwnProperty.call(n,a)&&n[a]&&l.push(n[a][0]),n[a]=0;for(t in i)Object.prototype.hasOwnProperty.call(i,t)&&(e[t]=i[t]);for(c&&c(r);l.length;)l.shift()();return o.push.apply(o,p||[]),_()}function _(){for(var e,r=0;r<o.length;r++){for(var _=o[r],t=!0,a=1;a<_.length;a++){var u=_[a];0!==n[u]&&(t=!1)}t&&(o.splice(r--,1),e=__webpack_require__(__webpack_require__.s=_[0]))}return e}var t={},n={1:0},o=[];function __webpack_require__(r){if(t[r])return t[r].exports;var _=t[r]={i:r,l:!1,exports:{}};return e[r].call(_.exports,_,_.exports,__webpack_require__),_.l=!0,_.exports}__webpack_require__.e=function(e){var r=[],_=n[e];if(0!==_)if(_)r.push(_[2]);else{var t=new Promise((function(r,t){_=n[e]=[r,t]}));r.push(_[2]=t);var o,a=document.createElement("script");a.charset="utf-8",a.timeout=120,__webpack_require__.nc&&a.setAttribute("nonce",__webpack_require__.nc),a.src=function(e){return __webpack_require__.p+""+({}[e]||e)+"-"+{30:"eabb516d5351f067ed6a",31:"4616fb32c9c42e5e7983",32:"4472d7ca246ae3ab280a",33:"fbf4437400036f489f31",34:"3d42949a38d37f889cfd",35:"7b58a3b74f5f72adb59c"}[e]+".js"}(e);var u=new Error;o=function(r){a.onerror=a.onload=null,clearTimeout(i);var _=n[e];if(0!==_){if(_){var t=r&&("load"===r.type?"missing":r.type),o=r&&r.target&&r.target.src;u.message="Loading chunk "+e+" failed.\n("+t+": "+o+")",u.name="ChunkLoadError",u.type=t,u.request=o,_[1](u)}n[e]=void 0}};var i=setTimeout((function(){o({type:"timeout",target:a})}),12e4);a.onerror=a.onload=o,document.head.appendChild(a)}return Promise.all(r)},__webpack_require__.m=e,__webpack_require__.c=t,__webpack_require__.d=function(e,r,_){__webpack_require__.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:_})},__webpack_require__.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},__webpack_require__.t=function(e,r){if(1&r&&(e=__webpack_require__(e)),8&r)return e;if(4&r&&"object"==typeof e&&e&&e.__esModule)return e;var _=Object.create(null);if(__webpack_require__.r(_),Object.defineProperty(_,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var t in e)__webpack_require__.d(_,t,function(r){return e[r]}.bind(null,t));return _},__webpack_require__.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return __webpack_require__.d(r,"a",r),r},__webpack_require__.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},__webpack_require__.p="",__webpack_require__.oe=function(e){throw console.error(e),e};var a=window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[],u=a.push.bind(a);a.push=r,a=a.slice();for(var i=0;i<a.length;i++)r(a[i]);var c=u;_()}([]);

View File

@ -1 +0,0 @@
!function(e){function r(r){for(var t,u,i=r[0],a=r[1],p=r[2],l=0,f=[];l<i.length;l++)u=i[l],Object.prototype.hasOwnProperty.call(n,u)&&n[u]&&f.push(n[u][0]),n[u]=0;for(t in a)Object.prototype.hasOwnProperty.call(a,t)&&(e[t]=a[t]);for(c&&c(r);f.length;)f.shift()();return o.push.apply(o,p||[]),_()}function _(){for(var e,r=0;r<o.length;r++){for(var _=o[r],t=!0,u=1;u<_.length;u++){var i=_[u];0!==n[i]&&(t=!1)}t&&(o.splice(r--,1),e=__webpack_require__(__webpack_require__.s=_[0]))}return e}var t={},n={1:0},o=[];function __webpack_require__(r){if(t[r])return t[r].exports;var _=t[r]={i:r,l:!1,exports:{}};return e[r].call(_.exports,_,_.exports,__webpack_require__),_.l=!0,_.exports}__webpack_require__.e=function(e){var r=[],_=n[e];if(0!==_)if(_)r.push(_[2]);else{var t=new Promise((function(r,t){_=n[e]=[r,t]}));r.push(_[2]=t);var o,u=document.createElement("script");u.charset="utf-8",u.timeout=120,__webpack_require__.nc&&u.setAttribute("nonce",__webpack_require__.nc),u.src=function(e){return __webpack_require__.p+""+({}[e]||e)+"-"+{30:"14ce5636a9c1047b9257",31:"0386dc2626a40ecdc22f",32:"2f739d408b32d85457bc",33:"ba7c443bc64ec750e1ba"}[e]+".js"}(e);var i=new Error;o=function(r){u.onerror=u.onload=null,clearTimeout(a);var _=n[e];if(0!==_){if(_){var t=r&&("load"===r.type?"missing":r.type),o=r&&r.target&&r.target.src;i.message="Loading chunk "+e+" failed.\n("+t+": "+o+")",i.name="ChunkLoadError",i.type=t,i.request=o,_[1](i)}n[e]=void 0}};var a=setTimeout((function(){o({type:"timeout",target:u})}),12e4);u.onerror=u.onload=o,document.head.appendChild(u)}return Promise.all(r)},__webpack_require__.m=e,__webpack_require__.c=t,__webpack_require__.d=function(e,r,_){__webpack_require__.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:_})},__webpack_require__.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},__webpack_require__.t=function(e,r){if(1&r&&(e=__webpack_require__(e)),8&r)return e;if(4&r&&"object"==typeof e&&e&&e.__esModule)return e;var _=Object.create(null);if(__webpack_require__.r(_),Object.defineProperty(_,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var t in e)__webpack_require__.d(_,t,function(r){return e[r]}.bind(null,t));return _},__webpack_require__.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return __webpack_require__.d(r,"a",r),r},__webpack_require__.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},__webpack_require__.p="",__webpack_require__.oe=function(e){throw console.error(e),e};var u=window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[],i=u.push.bind(u);u.push=r,u=u.slice();for(var a=0;a<u.length;a++)r(u[a]);var c=i;_()}([]);

View File

@ -8,5 +8,5 @@
return array(
'buildMode' => 'production',
'features' => array( 'adBlockerDetection','adsenseSetupV2','dashboardSharing','ga4ActivationBanner','ga4Reporting','gm3Components','gteSupport','userInput' ),
'features' => array( 'adsenseSetupV2','enhancedMeasurement','ga4Reporting','gm3Components','newsKeyMetrics','userInput' ),
);

View File

@ -9,36 +9,36 @@
return array(
'analytics-advanced-tracking' => array( "analytics-advanced-tracking-10a628cd2acd13ac224f.js", null ),
'googlesitekit-i18n' => array( "googlesitekit-i18n-e29c32171c9d96a19747.js", null ),
'googlesitekit-admin-css' => array( "googlesitekit-admin-css-86270a5b313ad7e93cc7.min.css", null ),
'googlesitekit-adminbar-css' => array( "googlesitekit-adminbar-css-a9d94ca654e371b3e168.min.css", null ),
'googlesitekit-wp-dashboard-css' => array( "googlesitekit-wp-dashboard-css-ce2b31afe246eb250ee7.min.css", null ),
'googlesitekit-vendor' => array( "googlesitekit-vendor-1695bdb02229e66571d8.js", null ),
'googlesitekit-runtime' => array( "runtime-082e69830d8b910a1de9.js", null ),
'googlesitekit-activation' => array( "googlesitekit-activation-3ec4e86f9a434b2cf5dc.js", null ),
'googlesitekit-ad-blocking-recovery' => array( "googlesitekit-ad-blocking-recovery-4d9d4a04c1d62a315e54.js", null ),
'googlesitekit-adminbar' => array( "googlesitekit-adminbar-d30d35706d33accb5a36.js", null ),
'googlesitekit-api' => array( "googlesitekit-api-6cbd49776eaf0783c565.js", null ),
'googlesitekit-components' => array( array( "googlesitekit-components-gm2-09d6f01d2ce7df2f7a7d.js", null ), array( "googlesitekit-components-gm3-8d9170f681fe8a5480b6.js", null ) ),
'googlesitekit-data' => array( "googlesitekit-data-73fee2b712bd87e9e5f8.js", null ),
'googlesitekit-datastore-forms' => array( "googlesitekit-datastore-forms-9f5b1d2d8d67d37e1a5e.js", null ),
'googlesitekit-datastore-location' => array( "googlesitekit-datastore-location-fbc24ccf1c0fd21ffb6d.js", null ),
'googlesitekit-datastore-site' => array( "googlesitekit-datastore-site-76011cf3a22620036165.js", null ),
'googlesitekit-datastore-ui' => array( "googlesitekit-datastore-ui-d8824c50c2cfa445e83b.js", null ),
'googlesitekit-datastore-user' => array( "googlesitekit-datastore-user-6463de7ed0d0c7800f36.js", null ),
'googlesitekit-entity-dashboard' => array( "googlesitekit-entity-dashboard-46bc733b1a18ffc0795c.js", null ),
'googlesitekit-main-dashboard' => array( "googlesitekit-main-dashboard-e9f2937e8ec0aefdfc19.js", null ),
'googlesitekit-modules' => array( "googlesitekit-modules-d86ee38f49ac9a8342ff.js", null ),
'googlesitekit-modules-adsense' => array( "googlesitekit-modules-adsense-6a997aba4be27d0f8b6d.js", null ),
'googlesitekit-modules-analytics' => array( "googlesitekit-modules-analytics-94f0fb39426f7f74999f.js", null ),
'googlesitekit-modules-analytics-4' => array( "googlesitekit-modules-analytics-4-fd769a7d7b34af8fd1ef.js", null ),
'googlesitekit-modules-optimize' => array( "googlesitekit-modules-optimize-51c1b162ed805a7b1cb1.js", null ),
'googlesitekit-modules-pagespeed-insights' => array( "googlesitekit-modules-pagespeed-insights-97a3038f35eff0863ac9.js", null ),
'googlesitekit-modules-search-console' => array( "googlesitekit-modules-search-console-1a8da5e4c0e302765c77.js", null ),
'googlesitekit-modules-tagmanager' => array( "googlesitekit-modules-tagmanager-f386140c76002165396c.js", null ),
'googlesitekit-polyfills' => array( "googlesitekit-polyfills-f104461a74f9ba986f19.js", null ),
'googlesitekit-settings' => array( "googlesitekit-settings-803d35bad0f9a6a40d4d.js", null ),
'googlesitekit-splash' => array( "googlesitekit-splash-e8beb52f6853cddfc79b.js", null ),
'googlesitekit-user-input' => array( "googlesitekit-user-input-60277cf082711b56604b.js", null ),
'googlesitekit-widgets' => array( "googlesitekit-widgets-4240fcd487ca967318dd.js", null ),
'googlesitekit-wp-dashboard' => array( "googlesitekit-wp-dashboard-796490a4b02cf9018d41.js", null ),
'googlesitekit-admin-css' => array( "googlesitekit-admin-css-16d61bf242934b018a55.min.css", null ),
'googlesitekit-adminbar-css' => array( "googlesitekit-adminbar-css-fa06a6db64aff464a52e.min.css", null ),
'googlesitekit-wp-dashboard-css' => array( "googlesitekit-wp-dashboard-css-35bbec942ca94079459a.min.css", null ),
'googlesitekit-vendor' => array( "googlesitekit-vendor-d7156c0af405e732626d.js", null ),
'googlesitekit-runtime' => array( "runtime-04b92d3488efbbf93c63.js", null ),
'googlesitekit-activation' => array( "googlesitekit-activation-cb66efa9e84af77b7835.js", null ),
'googlesitekit-ad-blocking-recovery' => array( "googlesitekit-ad-blocking-recovery-cc8de2c26df328b2d44c.js", null ),
'googlesitekit-adminbar' => array( "googlesitekit-adminbar-25a2b64d9c627e11dc1d.js", null ),
'googlesitekit-api' => array( "googlesitekit-api-43217e7f42fb8aa1768e.js", null ),
'googlesitekit-components' => array( array( "googlesitekit-components-gm2-221b449eb6293a7e79c4.js", null ), array( "googlesitekit-components-gm3-e9655098593952eb4f70.js", null ) ),
'googlesitekit-data' => array( "googlesitekit-data-8b5b77e401bbf560460b.js", null ),
'googlesitekit-datastore-forms' => array( "googlesitekit-datastore-forms-f2f2f5952c1835d6184a.js", null ),
'googlesitekit-datastore-location' => array( "googlesitekit-datastore-location-f01de561e1bb0f1a2bfb.js", null ),
'googlesitekit-datastore-site' => array( "googlesitekit-datastore-site-6ed20876a43f5a6f1b9b.js", null ),
'googlesitekit-datastore-ui' => array( "googlesitekit-datastore-ui-b271db06b38d39fe7b95.js", null ),
'googlesitekit-datastore-user' => array( "googlesitekit-datastore-user-abcbd6353ec1a1e13edc.js", null ),
'googlesitekit-entity-dashboard' => array( "googlesitekit-entity-dashboard-3d4326df64acd51c4de9.js", null ),
'googlesitekit-main-dashboard' => array( "googlesitekit-main-dashboard-ddd60197216bf70bf233.js", null ),
'googlesitekit-modules' => array( "googlesitekit-modules-6fd9effbf7629b0a709e.js", null ),
'googlesitekit-modules-adsense' => array( "googlesitekit-modules-adsense-3944ce11686c8744d4bb.js", null ),
'googlesitekit-modules-analytics' => array( "googlesitekit-modules-analytics-7de240f2784f840f21e8.js", null ),
'googlesitekit-modules-analytics-4' => array( "googlesitekit-modules-analytics-4-c58a014466010935f61e.js", null ),
'googlesitekit-modules-optimize' => array( "googlesitekit-modules-optimize-f931535316c48de1652e.js", null ),
'googlesitekit-modules-pagespeed-insights' => array( "googlesitekit-modules-pagespeed-insights-c86dafb5f26f6195b2dd.js", null ),
'googlesitekit-modules-search-console' => array( "googlesitekit-modules-search-console-d7b8b53563507cfa7379.js", null ),
'googlesitekit-modules-tagmanager' => array( "googlesitekit-modules-tagmanager-4bc964a64a14d157a777.js", null ),
'googlesitekit-polyfills' => array( "googlesitekit-polyfills-af766a3d7d8d5112308f.js", null ),
'googlesitekit-settings' => array( "googlesitekit-settings-6b850660937a507a7502.js", null ),
'googlesitekit-splash' => array( "googlesitekit-splash-2cc22f35feb51d4fd543.js", null ),
'googlesitekit-user-input' => array( "googlesitekit-user-input-84ceabc1ec0bdd5c5547.js", null ),
'googlesitekit-widgets' => array( "googlesitekit-widgets-dd54a9965c9c3d2cdf00.js", null ),
'googlesitekit-wp-dashboard' => array( "googlesitekit-wp-dashboard-f3173a7e08c4dd017281.js", null ),
);

View File

@ -11,7 +11,7 @@
* Plugin Name: Site Kit by Google
* Plugin URI: https://sitekit.withgoogle.com
* Description: Site Kit is a one-stop solution for WordPress users to use everything Google has to offer to make them successful on the web.
* Version: 1.101.0
* Version: 1.110.0
* Requires at least: 5.2
* Requires PHP: 5.6
* Author: Google
@ -26,7 +26,7 @@ if ( ! defined( 'ABSPATH' ) ) {
}
// Define most essential constants.
define( 'GOOGLESITEKIT_VERSION', '1.101.0' );
define( 'GOOGLESITEKIT_VERSION', '1.110.0' );
define( 'GOOGLESITEKIT_PLUGIN_MAIN_FILE', __FILE__ );
define( 'GOOGLESITEKIT_PHP_MINIMUM', '5.6.0' );
define( 'GOOGLESITEKIT_WP_MINIMUM', '5.2.0' );

Some files were not shown because too many files have changed in this diff Show More