| @@ -1,7 +1,12 @@ | ||
| 1 | 1 | <div |
| 2 | - <?php echo $wrapper_attr; //phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- contains attriutes and values together which are required here ?>> | |
| 3 | 2 | <?php |
| 3 | +// phpcs:disable WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound -- view template receives variables via extract(); prefixing is impractical. | |
| 4 | +if ( ! defined( 'ABSPATH' ) ) { | |
| 5 | + exit; | |
| 6 | +} | |
| 7 | +echo $wrapper_attr; //phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- contains attriutes and values together which are required here ?>> | |
| 8 | + <?php | |
| 4 | 9 | $section_tag = betterdocs()->template_helper->is_valid_tag( $faq_section_title_tag ); |
| 5 | 10 | echo wp_kses_post( '<' . $section_tag . ' class="' . esc_attr( $faq_heading_class ) . ' betterdocs-faq-section-title">' . esc_html( $faq_heading ) . '</' . $section_tag . '>' ); |
| 6 | 11 | ?> |
| 7 | 12 | |
| @@ -28,9 +33,9 @@ | ||
| 28 | 33 | continue; |
| 29 | 34 | } |
| 30 | 35 | $faq_icon_url = get_term_meta($term->term_id, 'faq_group_icon', true); |
| 31 | 36 | echo '<div class="betterdocs-faq-tab" data-term-id="' . esc_attr( $term->term_id ) . '">'; |
| 32 | - echo ( ! empty( $faq_icon_url ) ) ? '<img src="'.$faq_icon_url.'" width="24" height="24" class="faq-group-image" />' : ''; | |
| 37 | + echo ( ! empty( $faq_icon_url ) ) ? '<img src="' . esc_url( $faq_icon_url ) . '" width="24" height="24" class="faq-group-image" />' : ''; | |
| 33 | 38 | echo '<span class="faq-tab-title">' . esc_html( $term->name ) . '</span>'; |
| 34 | 39 | echo '</div>'; |
| 35 | 40 | } |
| 36 | 41 | echo '</div>'; |
| @@ -42,9 +47,9 @@ | ||
| 42 | 47 | } |
| 43 | 48 | |
| 44 | 49 | $faq_icon_url = get_term_meta($term->term_id, 'faq_group_icon', true); |
| 45 | 50 | echo '<div class="betterdocs-faq-tab" data-term-id="' . esc_attr( $term->term_id ) . '">'; |
| 46 | - echo ( ! empty( $faq_icon_url ) ) ? '<img src="'.$faq_icon_url.'" width="24" height="24" class="faq-group-image" />' : ''; | |
| 51 | + echo ( ! empty( $faq_icon_url ) ) ? '<img src="' . esc_url( $faq_icon_url ) . '" width="24" height="24" class="faq-group-image" />' : ''; | |
| 47 | 52 | echo '<span class="faq-tab-title">' . esc_html( $term->name ) . '</span>'; |
| 48 | 53 | |
| 49 | 54 | $faq_markup = '<svg class="betterdocs-faq-iconplus" width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg"> |
| 50 | 55 | <g clip-path="url(#clip0_8028_2975)"> |