0

I'm trying to replace some of the inline CSS created by a plugins function as below.

    public function custom_login_logo() {
    $extra_setting = $this->get_extra_options();
    if ( isset( $extra_setting['login_image']['url'] ) && ! empty( $extra_setting['login_image']['url'] ) ) {
        $login_logo = $extra_setting['login_image']['url'];
        echo '<style type="text/css">#login h1 a { background-image: url(\'' . esc_url( $login_logo ) . '\') !important; height:70px !important; width:310px !important; background-size: auto auto !important; }</style>';
    }
}

I'd like to change

background-size: auto auto !important

to

background-size: cover !important

Are there any solutions that I could place in my child themes functions.php file without editing the main plugin.

Thanks

  • 1
    since it is just css, can you override it printing your custom styles in your child theme? check out this question for further information about styles precedence: https://stackoverflow.com/questions/5473796/multiple-important-class-declarations-and-precedence – GrafiCode Apr 13 '22 at 12:46

0 Answers0