Changeset 153790 for sydney/1.79/widgets/fp-facts.php
- Timestamp:
- 08/25/2021 12:34:11 PM (4 years ago)
- Location:
- sydney/1.79
- Files:
-
- 1 edited
- 1 copied
-
. (copied) (copied from sydney/1.78)
-
widgets/fp-facts.php (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
sydney/1.79/widgets/fp-facts.php
r139705 r153790 28 28 $fact_four_icon = isset( $instance['fact_four_icon'] ) ? esc_html( $instance['fact_four_icon'] ) : ''; 29 29 ?> 30 <p><?php _e('You can find a list of the available icons ', 'sydney'); ?><a href="http://fortawesome.github.io/Font-Awesome/cheatsheet/" target="_blank"><?php _e('here.', 'sydney'); ?></a> <?php _e('Usage example: <strong>fa-android</strong>', 'sydney'); ?></p> 30 <p><?php _e('You can find a list of the available icons ', 'sydney'); ?><a href="http://fortawesome.github.io/Font-Awesome/cheatsheet/" target="_blank"><?php _e('here.', 'sydney'); ?></a> 31 <?php 32 if( get_option( 'sydney-fontawesome-v5' ) ) { 33 _e( 'Usage example: <strong>fas fa-cloud</strong> (solid). <strong>far fa-building</strong> (regular), <strong>fab fa-android</strong> (brands)', 'sydney' ); 34 } else { 35 _e( 'Usage example: <strong>fa-android</strong>', 'sydney' ); 36 } ?> 37 </p> 31 38 <p> 32 39 <label for="<?php echo $this->get_field_id('title'); ?>"><?php _e('Title', 'sydney'); ?></label> … … 128 135 extract($args); 129 136 137 $icon_prefix = sydney_get_fontawesome_prefix(); 138 130 139 $title = ( ! empty( $instance['title'] ) ) ? $instance['title'] : ''; 131 140 $title = apply_filters( 'widget_title', $title, $instance, $this->id_base ); 132 141 $fact_one = isset( $instance['fact_one'] ) ? esc_html( $instance['fact_one'] ) : ''; 133 142 $fact_one_max = isset( $instance['fact_one_max'] ) ? esc_html( $instance['fact_one_max'] ) : ''; 134 $fact_one_icon = isset( $instance['fact_one_icon'] ) ? esc_html( $i nstance['fact_one_icon'] ) : '';143 $fact_one_icon = isset( $instance['fact_one_icon'] ) ? esc_html( $icon_prefix . $instance['fact_one_icon'] ) : ''; 135 144 $fact_two = isset( $instance['fact_two'] ) ? esc_attr( $instance['fact_two'] ) : ''; 136 145 $fact_two_max = isset( $instance['fact_two_max'] ) ? esc_html( $instance['fact_two_max'] ) : ''; 137 $fact_two_icon = isset( $instance['fact_two_icon'] ) ? esc_html( $i nstance['fact_two_icon'] ) : '';146 $fact_two_icon = isset( $instance['fact_two_icon'] ) ? esc_html( $icon_prefix . $instance['fact_two_icon'] ) : ''; 138 147 $fact_three = isset( $instance['fact_three'] ) ? esc_attr( $instance['fact_three'] ) : ''; 139 148 $fact_three_max = isset( $instance['fact_three_max'] ) ? esc_html( $instance['fact_three_max'] ) : ''; 140 $fact_three_icon= isset( $instance['fact_three_icon'] ) ? esc_html( $i nstance['fact_three_icon'] ) : '';149 $fact_three_icon= isset( $instance['fact_three_icon'] ) ? esc_html( $icon_prefix . $instance['fact_three_icon'] ) : ''; 141 150 $fact_four = isset( $instance['fact_four'] ) ? esc_attr( $instance['fact_four'] ) : ''; 142 151 $fact_four_max = isset( $instance['fact_four_max'] ) ? esc_html( $instance['fact_four_max'] ) : ''; 143 $fact_four_icon = isset( $instance['fact_four_icon'] ) ? esc_html( $i nstance['fact_four_icon'] ) : '';152 $fact_four_icon = isset( $instance['fact_four_icon'] ) ? esc_html( $icon_prefix . $instance['fact_four_icon'] ) : ''; 144 153 145 154 echo $args['before_widget']; … … 151 160 <div class="col-md-3 col-sm-3"> 152 161 <div class="roll-counter"> 153 <i class=" fa<?php echo $fact_one_icon; ?>"></i>162 <i class="<?php echo $fact_one_icon; ?>"></i> 154 163 <div class="name-count"><?php echo $fact_one; ?></div> 155 164 <div class="numb-count" data-from="0" data-to="<?php echo $fact_one_max; ?>" data-speed="2000" data-waypoint-active="yes"><?php echo $fact_one_max; ?></div> … … 160 169 <div class="col-md-3 col-sm-3"> 161 170 <div class="roll-counter"> 162 <i class=" fa<?php echo $fact_two_icon; ?>"></i>171 <i class="<?php echo $fact_two_icon; ?>"></i> 163 172 <div class="name-count"><?php echo $fact_two; ?></div> 164 173 <div class="numb-count" data-from="0" data-to="<?php echo $fact_two_max; ?>" data-speed="2000" data-waypoint-active="yes"><?php echo $fact_two_max; ?></div> … … 169 178 <div class="col-md-3 col-sm-3"> 170 179 <div class="roll-counter"> 171 <i class=" fa<?php echo $fact_three_icon; ?>"></i>180 <i class="<?php echo $fact_three_icon; ?>"></i> 172 181 <div class="name-count"><?php echo $fact_three; ?></div> 173 182 <div class="numb-count" data-from="0" data-to="<?php echo $fact_three_max; ?>" data-speed="2000" data-waypoint-active="yes"><?php echo $fact_three_max; ?></div> … … 178 187 <div class="col-md-3 col-sm-3"> 179 188 <div class="roll-counter"> 180 <i class=" fa<?php echo $fact_four_icon; ?>"></i>189 <i class="<?php echo $fact_four_icon; ?>"></i> 181 190 <div class="name-count"><?php echo $fact_four; ?></div> 182 191 <div class="numb-count" data-from="0" data-to="<?php echo $fact_four_max; ?>" data-speed="2000" data-waypoint-active="yes"><?php echo $fact_four_max; ?></div>
Note: See TracChangeset
for help on using the changeset viewer.