predefined_api_key example

<div id="akismet-plugin-container"> <div class="akismet-masthead"> <div class="akismet-masthead__inside-container"> <?php Akismet::view( 'logo' ); ?> </div> </div> <div class="akismet-lower"> <?php Akismet_Admin::display_status();?> <div class="akismet-boxes"> <?php
            if ( Akismet::predefined_api_key() ) {
                Akismet::view( 'predefined' );
            } elseif ( $akismet_user && in_array( $akismet_user->status, array( 'active', 'active-dunning', 'no-sub', 'missing', 'cancelled', 'suspended' ) ) ) {
                Akismet::view( 'connect-jp', compact( 'akismet_user' ) );
            } else {
                Akismet::view( 'activate' );
            }

            ?> </div> </div> </div>
'<p>' . esc_html__( 'Akismet filters out spam, so you can focus on more important things.' , 'akismet') . '</p>' .
                            '<p>' . esc_html__( 'On this page, you are able to update your Akismet settings and view spam stats.' , 'akismet') . '</p>',
                    )
                );

                $current_screen->add_help_tab(
                    array(
                        'id'        => 'settings',
                        'title'        => __( 'Settings' , 'akismet'),
                        'content'    =>
                            '<p><strong>' . esc_html__( 'Akismet Configuration' , 'akismet') . '</strong></p>' .
                            ( Akismet::predefined_api_key() ? '' : '<p><strong>' . esc_html__( 'API Key' , 'akismet') . '</strong> - ' . esc_html__( 'Enter/remove an API key.' , 'akismet') . '</p>' ) .
                            '<p><strong>' . esc_html__( 'Comments' , 'akismet') . '</strong> - ' . esc_html__( 'Show the number of approved comments beside each comment author in the comments list page.' , 'akismet') . '</p>' .
                            '<p><strong>' . esc_html__( 'Strictness' , 'akismet') . '</strong> - ' . esc_html__( 'Choose to either discard the worst spam automatically or to always put all spam in spam folder.' , 'akismet') . '</p>',
                    )
                );

                if ( ! Akismet::predefined_api_key() ) {
                    $current_screen->add_help_tab(
                        array(
                            'id'        => 'account',
                            'title'        => __( 'Account' , 'akismet'),
                            'content'    =>
                                
<div class="akismet-card"> <div class="akismet-section-header"> <h2 class="akismet-section-header__label"> <span><?php esc_html_e( 'Settings' , 'akismet'); ?></span> </h2> </div> <div class="inside"> <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> </div> </div> <?php endif; ?> <?php if ( isset( $_GET['ssl_status'] ) ) : ?>
Home | Imprint | This part of the site doesn't use cookies.