PluginProbe
ShopBuilder – WooCommerce Builder For Elementor / 3.2.4
ShopBuilder – WooCommerce Builder For Elementor v3.2.4
3.4.2 3.4.1 3.4.0 2.0.1 2.0.2 2.0.3 2.1.0 2.1.1 2.1.10 2.1.11 2.1.12 2.1.13 2.1.14 2.1.15 2.1.2 2.1.3 2.1.4 2.1.5 2.1.6 2.1.7 2.1.8 2.1.9 2.2.0 2.2.1 2.2.2 All 63 releases
shopbuilder / templates / elementor / general / slider / slider-layout1.php

slider-layout1.php in ShopBuilder – WooCommerce Builder For Elementor 3.2.4, at templates/elementor/general/slider/slider-layout1.php

229 lines 5.5 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Template: Slider Layout 1.
4 *
5 * @package RadiusTheme\SB
6 */
7
8 /**
9 * Template variables:
10 *
11 * @var $grid string
12 * @var $class string
13 * @var $p_id int
14 * @var $img_args array
15 * @var $p_link string
16 * @var $items array
17 * @var $rating_args array
18 * @var $add_to_cart string
19 * @var $title_tag string
20 * @var $excerpt_limit string
21 * @var $excerpt string
22 * @var $title_class string
23 * @var $title_link bool
24 * @var $title string
25 * @var $badge_class string
26 * @var $action_btn_preset string
27 * @var $action_btn_position string
28 * @var $swatch_position string
29 * @var $swatch_type string
30 * @var $has_attributes bool
31 * @var $raw_settings array
32 */
33
34 use RadiusTheme\SB\Helpers\Fns;
35
36 // Do not allow directly accessing this file.
37 if ( ! defined( 'ABSPATH' ) ) {
38 exit( 'This script cannot be accessed directly.' );
39 }
40
41 global $product;
42
43 $classes = esc_attr( $grid ) . ' ' . esc_attr( $class );
44 $swatch_title_class = $has_attributes && in_array( 'swatches', $items, true ) && 'title' === $swatch_position ? 'title-with-swatch' : 'title-with-no-swatch';
45 $swatch_price_class = $has_attributes && in_array( 'swatches', $items, true ) && 'price' === $swatch_position ? ' price-with-swatch' : '';
46 ?>
47
48 <div <?php wc_product_class( $classes, $product ); ?> data-id="<?php echo absint( $p_id ); ?>">
49 <?php
50 /**
51 * Before product items hook.
52 */
53 do_action( 'rtsb/before/shop/product/item' );
54 ?>
55
56 <div class="rtsb-grid-item">
57 <div class="rtsb-product-img">
58 <?php
59 /**
60 * Before product image hook.
61 */
62 do_action( 'rtsb/before/shop/product/image' );
63
64 /**
65 * Product image hook.
66 *
67 * @hooked RadiusTheme\SB\Controllers\Hooks\ActionHooks::render_image 10
68 */
69 do_action( 'rtsb/shop/product/image', $img_args, $raw_settings );
70
71 /**
72 * Sale Badge.
73 */
74 if ( ! empty( $p_sale ) ) {
75 ?>
76 <div class="rtsb-promotion">
77 <?php
78 Fns::get_badge_html( $p_sale, $badge_class );
79 ?>
80 </div>
81 <?php
82 }
83
84 /**
85 * Action buttons above image.
86 */
87 Fns::print_html( Fns::get_formatted_action_buttons( $items, $add_to_cart, $action_btn_preset, $action_btn_position, 'top' ) );
88
89 /**
90 * After product image hook.
91 */
92 do_action( 'rtsb/after/shop/product/image', $raw_settings );
93 ?>
94 </div><!-- .rtsb-product-img -->
95
96 <div class="rtsb-product-content">
97 <?php
98 /**
99 * Before product content hook.
100 */
101 do_action( 'rtsb/before/shop/product/content' );
102
103 /**
104 * Product Swatches.
105 */
106 if ( in_array( 'swatches', $items, true ) && 'top' === $swatch_position ) {
107 Fns::get_product_swatches( $swatch_type );
108 }
109
110 /**
111 * Product Categories.
112 */
113 if ( in_array( 'categories', $items, true ) ) {
114 ?>
115 <div class="rtsb-product-category">
116 <?php
117 Fns::get_categories_list( $p_id );
118 ?>
119 </div>
120 <?php
121 }
122 /**
123 * Product Brands.
124 */
125 if ( in_array( 'brands', $items, true ) ) {
126 ?>
127 <div class="rtsb-brand-category">
128 <?php
129 Fns::get_brands_list( $p_id );
130 ?>
131 </div>
132 <?php
133 }
134
135 /**
136 * Before product title hook.
137 */
138 do_action( 'rtsb/before/shop/product/title' );
139
140 /**
141 * Product Title.
142 */
143 if ( in_array( 'title', $items, true ) ) {
144 ?>
145 <div class="rtsb-product-title-wrapper <?php echo esc_attr( $swatch_title_class ); ?>">
146 <<?php Fns::print_validated_html_tag( $title_tag ); ?> class="<?php echo esc_attr( $title_class ); ?>">
147 <?php if ( $title_link ) { ?>
148 <a class="woocommerce-LoopProduct-link" href="<?php echo esc_url( $p_link ); ?>"><?php Fns::print_html( $title ); ?></a>
149 <?php
150 } else {
151 Fns::print_html( $title );
152 }
153 ?>
154 </<?php Fns::print_validated_html_tag( $title_tag ); ?>>
155 <?php
156 if ( in_array( 'swatches', $items, true ) && 'title' === $swatch_position ) {
157 Fns::get_product_swatches( $swatch_type );
158 }
159 ?>
160 </div>
161 <?php
162 }
163
164 /**
165 * After product title hook.
166 */
167 do_action( 'rtsb/after/shop/product/title' );
168
169 /**
170 * Product Rating.
171 */
172 if ( in_array( 'rating', $items, true ) ) {
173 Fns::get_product_rating_html( $rating_args );
174 }
175
176 /**
177 * Product Short Description.
178 */
179 if ( in_array( 'excerpt', $items, true ) ) {
180 ?>
181 <div class="product-short-description rtsb-text-limit limit-<?php echo esc_attr( $excerpt_limit ); ?>">
182 <?php
183 Fns::print_html( $excerpt );
184 ?>
185 </div>
186 <?php
187 }
188
189 /**
190 * Product Price.
191 */
192 if ( in_array( 'price', $items, true ) ) {
193 ?>
194 <div class="product-price rtsb-item-space-between">
195 <div class="price-wrapper">
196 <?php
197 woocommerce_template_single_price();
198 ?>
199 </div>
200 <?php
201 if ( in_array( 'swatches', $items, true ) && 'price' === $swatch_position ) {
202 Fns::get_product_swatches( $swatch_type );
203 }
204 ?>
205 </div>
206 <?php
207 }
208
209 /**
210 * Action buttons after content.
211 */
212 Fns::print_html( Fns::get_formatted_action_buttons( $items, $add_to_cart, $action_btn_preset, $action_btn_position, 'bottom' ) );
213
214 /**
215 * After product content hook.
216 */
217 do_action( 'rtsb/after/shop/product/content', $raw_settings );
218 ?>
219 </div><!-- .rtsb-product-content -->
220 </div><!-- .rtsb-grid-item -->
221
222 <?php
223 /**
224 * After product item hook.
225 */
226 do_action( 'rtsb/after/shop/product/item' );
227 ?>
228 </div><!-- .rtsb-product -->
229