| @@ -62,8 +62,11 @@ | ||
| 62 | 62 | ], |
| 63 | 63 | $settings |
| 64 | 64 | ); |
| 65 | 65 | |
| 66 | + // Fill display flags the request may have omitted (see trait) before the render loop reads them. | |
| 67 | + $settings = array_merge( $this->loadmore_display_defaults(), $settings ); | |
| 68 | + | |
| 66 | 69 | $ajaxposts = $this->query_args( $settings ); |
| 67 | 70 | |
| 68 | 71 | ob_start(); |
| 69 | 72 | $found_posts = false; |
| @@ -94,11 +97,12 @@ | ||
| 94 | 97 | <?php if ( $settings['show_image'] === 'yes' ) : ?> |
| 95 | 98 | <img class="upk-img" src="<?php echo esc_url( $image_src ); ?>" alt="<?php echo esc_attr( $title ); ?>"> |
| 96 | 99 | <?php endif; ?> |
| 97 | 100 | |
| 98 | - <?php if ( ! empty( $settings['show_item_icon']['value'] ) ) : ?> | |
| 101 | + <?php $upk_item_icon = ultimate_post_kit_sanitize_request_icon( $settings['show_item_icon'] ?? null ); ?> | |
| 102 | + <?php if ( $upk_item_icon ) : ?> | |
| 99 | 103 | <div class="upk-title-icon"> |
| 100 | - <?php \Elementor\Icons_Manager::render_icon( $settings['show_item_icon'], [ 'aria-hidden' => 'true', 'class' => 'fa-fw' ] ); ?> | |
| 104 | + <?php \Elementor\Icons_Manager::render_icon( $upk_item_icon, [ 'aria-hidden' => 'true', 'class' => 'fa-fw' ] ); ?> | |
| 101 | 105 | </div> |
| 102 | 106 | <?php endif; ?> |
| 103 | 107 | |
| 104 | 108 | <?php if ( ! isset( $settings['show_title'] ) || $settings['show_title'] === 'yes' ) : ?> |