PluginProbe
WebberZone Top 10 — Popular Posts / 4.5.2
WebberZone Top 10 — Popular Posts v4.5.2
4.5.2 4.5.1 4.5.0 4.4.3 4.4.2 4.4.1 4.4.0 4.3.4 4.3.3 4.3.2 4.3.1 4.3.0 trunk 1.0 1.0.1 1.1 1.2 1.3 1.4 1.4.1 1.5 1.5.1 1.5.2 1.5.3 1.6 All 118 releases
← All changes | includes/admin/settings/class-settings-wizard-api.php +6 -2 4.4.0 → 4.5.2 View file →
@@ -422,9 +422,9 @@
422 422 $settings_sanitize = $this->settings_sanitize;
423 423
424 424 // Check if we have a specific sanitizer for this type.
425 425 if ( is_callable( array( $settings_sanitize, "sanitize_{$type}_field" ) ) ) {
426 - return call_user_func( array( $settings_sanitize, "sanitize_{$type}_field" ), $value );
426 + return call_user_func( array( $settings_sanitize, "sanitize_{$type}_field" ), $value, $setting_config );
427 427 }
428 428
429 429 // Fallback to basic sanitization.
430 430 if ( is_array( $value ) ) {
@@ -647,9 +647,13 @@
647 647
648 648 echo '<tr>';
649 649 echo '<th scope="row">';
650 650 if ( ! empty( $args['name'] ) ) {
651 - echo '<label for="' . esc_attr( $setting_id ) . '">' . esc_html( wp_strip_all_tags( $args['name'] ) ) . '</label>';
651 + if ( in_array( $type, array( 'header', 'repeater' ), true ) ) {
652 + echo wp_kses_post( $args['name'] );
653 + } else {
654 + echo '<label for="' . esc_attr( $this->settings_form->get_field_id( $args ) ) . '">' . wp_kses_post( $args['name'] ) . '</label>';
655 + }
652 656 }
653 657 echo '</th>';
654 658 echo '<td>';
655 659 \call_user_func( $callback, $args );