Plugin Directory

Changeset 3074587


Ignore:
Timestamp:
04/21/2024 03:19:19 PM (21 months ago)
Author:
Hakik
Message:

v1.1.3: Security check using Plugin Check (PCP) & WordPress 6.5 compatibility

Location:
ideal-wp-login-logo-changer/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • ideal-wp-login-logo-changer/trunk/ideal-wp-login-logo-changer.php

    r2973931 r3074587  
    33Plugin Name: Custom Login Logo
    44description: Change the default WordPress logo by uploading your site logo for the login page.
    5 Version: 1.1.2
     5Version: 1.1.3
    66Author: Hakik Zaman
    77Author URI: https://github.com/hakikz
     8Text Domain: ideal-wp-login-logo-changer
    89License: GPLv2 or later
    910License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    2223
    2324/*Defining Constant*/
    24 define("IWLLC_VERSION", '1.1.2');
     25define("IWLLC_VERSION", '1.1.3');
    2526
    2627/*Add body class for options page*/
    2728function iwllc_admin_body_class( $classes ) {
    2829    global $pagenow;
    29 
    30     if ( in_array( $pagenow, array( 'options-general.php' ), true ) &&  $_GET['page'] == 'change_login_logo' ) {
     30    $screen = get_current_screen();
     31
     32    if ( in_array( $pagenow, array( 'options-general.php' ), true ) && $screen->id === 'settings_page_change_login_logo' ) {
    3133        $classes .= ' idllc-option-page';
    3234    }
     
    4042function iwllc_styles_option_page(){
    4143    global $pagenow;
    42 
    43     if ( in_array( $pagenow, array( 'options-general.php' ), true ) &&  $_GET['page'] == 'change_login_logo' ) {
     44    $screen = get_current_screen();
     45
     46    if ( in_array( $pagenow, array( 'options-general.php' ), true ) &&  $screen->id === 'settings_page_change_login_logo' ) {
    4447        ?>
    4548            <style type="text/css">
     
    9295    ?>
    9396    <div class="wrap">
    94         <h1><?php echo __( 'Custom Login Logo Settings' ); ?></h1>
    95         <p><?php echo __( 'Change the the default WordPress logo and set your own site logo.' ); ?></p>
     97        <h1><?php echo esc_html__( 'Custom Login Logo Settings', 'ideal-wp-login-logo-changer' ); ?></h1>
     98        <p><?php echo esc_html__( 'Change the the default WordPress logo and set your own site logo.', 'ideal-wp-login-logo-changer' ); ?></p>
    9699        <form method="post" action="options.php">
    97100            <?php settings_fields( 'iwllc_change_login_options_group' ); ?>
     
    110113               
    111114                <tr valign="top">
    112                     <th scope="row"><?php echo __( 'Set Logo' ); ?> </th>
     115                    <th scope="row"><?php echo esc_html__( 'Set Logo', 'ideal-wp-login-logo-changer' ); ?> </th>
    113116                    <td>
    114117                        <input type="text" id="iwllc_wp_logo_url" name="iwllc_wp_logo_url" value="<?php echo esc_attr( get_option('iwllc_wp_logo_url') ); ?>" />
    115118                        <input type="button" name="iwllc-upload-btn" id="iwllc-upload-btn" class="button-secondary" value="Upload Logo">
    116                         <p class="description"><i><?php echo __( 'This Image will be displayed in Login Page' ) ?></i></p>
     119                        <p class="description"><i><?php echo esc_html__( 'This Image will be displayed in Login Page', 'ideal-wp-login-logo-changer' ) ?></i></p>
    117120                    </td>
    118121                </tr>
     
    120123                <!-- Choose Background Type Section -->
    121124                <tr valign="top">
    122                     <th scope="row"><?php echo __( 'Set Background Type' ); ?></th>
     125                    <th scope="row"><?php echo esc_html__( 'Set Background Type', 'ideal-wp-login-logo-changer' ); ?></th>
    123126                    <td>
    124127                        <select class="iwllc_wp_bg_select" name="iwllc_wp_set_bg">
     
    126129                            <option value="image" <?php echo ( get_option('iwllc_wp_set_bg') === 'image' ) ? 'selected' : ''  ?>>Image</option>
    127130                        </select>
    128                         <p class="description"><i><?php echo __( 'Default type is `Color`' ) ?></i></p>
     131                        <p class="description"><i><?php echo esc_html__( 'Default type is `Color`', 'ideal-wp-login-logo-changer' ) ?></i></p>
    129132                    </td>
    130133                </tr>
     
    132135                <!-- Background Color Section -->
    133136                <tr class="type_color" valign="top">
    134                     <th scope="row"><?php echo __( 'Set Background Color' ); ?> </th>
     137                    <th scope="row"><?php echo esc_html__( 'Set Background Color', 'ideal-wp-login-logo-changer' ); ?> </th>
    135138                    <td>
    136139                        <input type="text" class="iwllc_wp_bg_color" id="iwllc_wp_bg_color" name="iwllc_wp_bg_color" value="<?php echo esc_attr( get_option('iwllc_wp_bg_color', '#f0f0f1') ); ?>" data-default-color="#f0f0f1" />
    137                         <p class="description"><i><?php echo __( 'Set your desired color, to change the login page background color' ) ?></i></p>
     140                        <p class="description"><i><?php echo esc_html__( 'Set your desired color, to change the login page background color', 'ideal-wp-login-logo-changer' ) ?></i></p>
    138141                    </td>
    139142                </tr>
     
    152155
    153156                <tr class="type_image" valign="top">
    154                     <th scope="row"><?php echo __( 'Set Background Image' ); ?> </th>
     157                    <th scope="row"><?php echo esc_html__( 'Set Background Image', 'ideal-wp-login-logo-changer' ); ?> </th>
    155158                    <td>
    156159                        <input type="text" id="iwllc_wp_bg_img_url" name="iwllc_wp_bg_img_url" value="<?php echo esc_attr( get_option('iwllc_wp_bg_img_url') ); ?>" />
    157160                        <input type="button" name="iwllc-upload-btn" id="iwllc-upload-btn" class="button-secondary" value="Upload Logo">
    158                         <p class="description"><i><?php echo __( 'This Image will be displayed as background image of Login Page' ) ?></i></p>
     161                        <p class="description"><i><?php echo esc_html__( 'This Image will be displayed as background image of Login Page' ) ?></i></p>
    159162                    </td>
    160163                </tr>
     
    162165                <!-- Logo Custom Link Section -->
    163166                <tr valign="top">
    164                     <th scope="row"><?php echo __( 'Set Your Logo Link' ); ?> </th>
     167                    <th scope="row"><?php echo esc_html__( 'Set Your Logo Link', 'ideal-wp-login-logo-changer' ); ?> </th>
    165168                    <td>
    166169                        <input type="url" id="iwllc_wp_logo_link" name="iwllc_wp_logo_link" value="<?php echo esc_attr( get_option('iwllc_wp_logo_link') ); ?>" />
    167                         <p class="description"><i><?php echo __( 'Set your desired link, to redirect after clicking on your logo' ) ?></i></p>
     170                        <p class="description"><i><?php echo esc_html__( 'Set your desired link, to redirect after clicking on your logo' ) ?></i></p>
    168171                    </td>
    169172                </tr>
     
    171174                <!-- Logo Width Settings Section -->
    172175                <tr valign="top">
    173                     <th scope="row"><?php echo __( 'Width' ); ?></th>
     176                    <th scope="row"><?php echo esc_html__( 'Width', 'ideal-wp-login-logo-changer' ); ?></th>
    174177                    <td>
    175178                        <input type="text" name="iwllc_wp_logo_width" value="<?php echo esc_attr( get_option('iwllc_wp_logo_width') ); ?>" />
    176                         <p class="description"><i><?php echo __( 'Default width is 100%' ) ?></i></p>
     179                        <p class="description"><i><?php echo esc_html__( 'Default width is 100%' ) ?></i></p>
    177180                    </td>
    178181                </tr>
     
    180183                <!-- Logo Height Settings Section -->
    181184                <tr valign="top">
    182                     <th scope="row"><?php echo __( 'Height' ); ?></th>
     185                    <th scope="row"><?php echo esc_html__( 'Height', 'ideal-wp-login-logo-changer' ); ?></th>
    183186                    <td>
    184187                        <input type="text" name="iwllc_wp_logo_height" value="<?php echo esc_attr( get_option('iwllc_wp_logo_height') ); ?>" />                 
    185                         <p class="description"><i><?php echo __( 'Default height is 100px' ) ?></i></p>
     188                        <p class="description"><i><?php echo esc_html__( 'Default height is 100px', 'ideal-wp-login-logo-changer' ) ?></i></p>
    186189                    </td>
    187190                </tr>
     
    271274    $style .= '</style>';
    272275
    273     echo $style;
     276    echo wp_kses( $style, array(
     277        "style" => array()
     278    ) );
    274279}
    275280add_action( 'login_head', 'iwllc_wordpress_custom_login_logo' );
  • ideal-wp-login-logo-changer/trunk/readme.txt

    r2973931 r3074587  
    33Tags: Change WP default logo, WordPress Logo change, Login Logo, Custom logo, WP admin logo,
    44Requires at least: 5.8
    5 Tested up to: 6.3
     5Tested up to: 6.5
    66Requires PHP: 5.2.4
    7 Stable tag: 1.1.2
     7Stable tag: 1.1.3
    88License: GPLv2 or later
    99License URI: https://www.gnu.org/licenses/gpl-2.0.html
     
    6262== Changelog ==
    6363
     64= 1.1.3 [21-04-2024] =
     65* Security: Whole codebase using PCP (Plugin Check Plugin).
     66* Compatibility: WordPress 6.5.
     67
    6468= 1.1.2 [02-10-2023] =
    6569* Enhancement: Improved the option page style.
Note: See TracChangeset for help on using the changeset viewer.