| @@ -1,5 +1,13 @@ | ||
| 1 | 1 | <?php |
| 2 | +/** | |
| 3 | + * Dashboard counters widget. | |
| 4 | + * | |
| 5 | + * @package Formidable | |
| 6 | + * | |
| 7 | + * @var array $template Widget data with a 'counters' array. Each counter has: heading, type, counter, cta and optional items. | |
| 8 | + */ | |
| 9 | + | |
| 2 | 10 | if ( ! defined( 'ABSPATH' ) ) { |
| 3 | 11 | die( 'You are not allowed to call this page directly.' ); |
| 4 | 12 | } |
| 5 | 13 | |
| @@ -18,11 +26,11 @@ | ||
| 18 | 26 | <?php if ( 'currency' === $counter['type'] ) : ?> |
| 19 | 27 | <div class="frm-flex-box frm-gap-md"> |
| 20 | 28 | <?php foreach ( $counter['items'] as $item ) : ?> |
| 21 | 29 | <b> |
| 22 | - <?php echo esc_attr( $item['counter_label']['symbol_left'] ); ?> | |
| 30 | + <?php echo esc_html( $item['counter_label']['symbol_left'] ); ?> | |
| 23 | 31 | <span class="frm-counter" data-type="<?php echo esc_attr( $counter['type'] ); ?>" data-locale="<?php echo esc_attr( get_locale() ); ?>" data-counter="<?php echo (int) $item['counter']; ?>"><?php echo (int) $item['counter']; ?></span> |
| 24 | - <?php echo esc_attr( $item['counter_label']['symbol_right'] ); ?> | |
| 32 | + <?php echo esc_html( $item['counter_label']['symbol_right'] ); ?> | |
| 25 | 33 | </b> |
| 26 | 34 | <?php endforeach; ?> |
| 27 | 35 | </div> |
| 28 | 36 | <?php else : ?> |