PluginProbe
Polylang / 2.7.3
Polylang v2.7.3
3.8.9 3.8.8 3.8.7 3.8.6 3.8.5 3.8.4 3.8.3 2.7 2.7.0.1 2.7.1 2.7.2 2.7.3 2.7.4 2.8 2.8.1 2.8.2 2.8.3 2.8.4 2.9 2.9.1 2.9.2 3.0 3.0.1 3.0.2 3.0.3 All 233 releases
← All changes | include/widget-languages.php +2 -5 2.82.7.3 View file →
@@ -1,8 +1,5 @@
1 1 <?php
2 -/**
3 - * @package Polylang
4 - */
5 2
6 3 /**
7 4 * The language switcher widget
8 5 *
@@ -137,9 +134,9 @@
137 134
138 135 // Remove all options if dropdown is checked
139 136 $( '.widgets-sortables,.control-section-sidebar' ).on( 'change', '.pll-dropdown', function() {
140 137 var this_id = $( this ).parent().parent().parent().children( '.widget-id' ).attr( 'value' );
141 - pll_toggle( $( '.no-dropdown-' + this_id ), true != $( this ).prop( 'checked' ) );
138 + pll_toggle( $( '.no-dropdown-' + this_id ), 'checked' != $( this ).attr( 'checked' ) );
142 139 } );
143 140
144 141 // Disallow unchecking both show names and show flags
145 142 var options = ['-show_flags', '-show_names'];
@@ -145,9 +142,9 @@
145 142 var options = ['-show_flags', '-show_names'];
146 143 $.each( options, function( i, v ) {
147 144 $( '.widgets-sortables,.control-section-sidebar' ).on( 'change', '.pll' + v, function() {
148 145 var this_id = $( this ).parent().parent().parent().children( '.widget-id' ).attr( 'value' );
149 - if ( true != $( this ).prop( 'checked' ) ) {
146 + if ( 'checked' != $( this ).attr( 'checked' ) ) {
150 147 $( '#widget-' + this_id + options[ 1-i ] ).prop( 'checked', true );
151 148 }
152 149 } );
153 150 } );