WPML
Estado
Abierto
Notificado para
WPML Multilingual CMS 4.4.10

Resumen del problema

Si añade un selector de idiomas en un área de widgets, notará que las opciones de color de Hover no se muestran en el front-end.

Solución alternativa

Para solucionar esto:


  • Por favor, antes de continuar, haga una copia de seguridad completa de su sitio.

  • Abra /wp-content/plugins/sitepress-multilingual-cms/classes/language-switcher/class-wpml-ls-inline-styles.php, LÍNEA 148.

  • Reemplace esto:
    if ( $slot->get( 'font_other_hover' ) || $slot->get( 'background_other_hover' ) ) {
        	$css .= "$wrapper_class a:hover,$wrapper_class a:focus {";
        	$css .= $slot->get( 'font_other_hover' ) ? "color:{$slot->get( 'font_other_hover' )};" : '';
        	$css .= $slot->get( 'background_other_hover' ) ? "background-color:{$slot->get( 'background_other_hover' )};" : '';
        	$css .= '}';
    }


  • Por:
    if ( $slot->get( 'font_other_hover' ) || $slot->get( 'background_other_hover' ) ) {
    	$css .= "$wrapper_class .wpml-ls-item a:hover,$wrapper_class .wpml-ls-item a:focus {";
    	$css .= $slot->get( 'font_other_hover' ) ? "color:{$slot->get( 'font_other_hover' )};" : '';
    	$css .= $slot->get( 'background_other_hover' ) ? "background-color:{$slot->get( 'background_other_hover' )};" : '';
    	$css .= '}';
    }


  • Luego busque la línea 141.

  • Reemplace esto:
    if ( $slot->get( 'font_other_normal' ) || $slot->get( 'background_other_normal' ) ) {
    			$css .= "$wrapper_class>a:link {";
    			$css .= $slot->get( 'font_other_normal' ) ? "color:{$slot->get( 'font_other_normal' )};" : '';
    			$css .= $slot->get( 'background_other_normal' ) ? "background-color:{$slot->get( 'background_other_normal' )};" : '';
    			$css .= '}';
    }


  • Por:
    if ( $slot->get( 'font_other_normal' ) || $slot->get( 'background_other_normal' ) ) {
    			$css .= "$wrapper_class .wpml-ls-item a:link {";
    			$css .= $slot->get( 'font_other_normal' ) ? "color:{$slot->get( 'font_other_normal' )};" : '';
    			$css .= $slot->get( 'background_other_normal' ) ? "background-color:{$slot->get( 'background_other_normal' )};" : '';
    			$css .= '}';
    }

Todos los problemas conocidos →