PluginProbe ʕ •ᴥ•ʔ
Shortcodes and extra features for Phlox theme / 2.17.14
Shortcodes and extra features for Phlox theme v2.17.14
2.17.20 trunk 1.0.0 1.0.1 1.0.2 1.0.3 1.0.6 1.0.9 1.1.0 1.3.0 1.3.1 1.3.10 1.3.14 1.3.2 1.3.3 1.3.6 1.4.0 1.4.1 1.4.2 1.5.0 1.5.2 1.6.0 1.6.2 1.6.4 1.7.0 1.7.2 2.10.0 2.10.1 2.10.3 2.10.5 2.10.7 2.10.8 2.10.9 2.11.0 2.11.1 2.11.2 2.12.0 2.14.0 2.15.0 2.15.2 2.15.4 2.15.5 2.15.6 2.15.7 2.15.8 2.15.9 2.16.0 2.16.1 2.16.2 2.16.3 2.16.4 2.17.0 2.17.1 2.17.12 2.17.13 2.17.14 2.17.15 2.17.16 2.17.2 2.17.3 2.17.4 2.17.5 2.17.6 2.17.8 2.17.9 2.4.12 2.4.13 2.4.14 2.4.16 2.4.18 2.4.19 2.4.9 2.5.0 2.5.1 2.5.10 2.5.11 2.5.12 2.5.13 2.5.14 2.5.15 2.5.16 2.5.17 2.5.19 2.5.2 2.5.20 2.5.3 2.5.7 2.5.8 2.5.9 2.6.0 2.6.1 2.6.10 2.6.12 2.6.13 2.6.14 2.6.15 2.6.16 2.6.17 2.6.19 2.6.2 2.6.20 2.6.4 2.6.5 2.6.7 2.7.0 2.7.1 2.7.10 2.7.11 2.7.12 2.7.13 2.7.14 2.7.2 2.7.3 2.7.4 2.7.5 2.7.6 2.7.7 2.7.8 2.7.9 2.8.0 2.8.1 2.8.2 2.8.3 2.8.4 2.8.5 2.8.6 2.8.7 2.8.9 2.9.0 2.9.12 2.9.14 2.9.15 2.9.16 2.9.17 2.9.18 2.9.19 2.9.2 2.9.20 2.9.21 2.9.22 2.9.3 2.9.4 2.9.5 2.9.6 2.9.7 2.9.8
auxin-elements / includes / elements / recent-posts-land-style.php
auxin-elements / includes / elements Last commit date
about-widget.php 1 year ago accordion-widget.php 1 year ago accordion.php 1 year ago attachment-url.php 1 year ago audio.php 1 year ago before-after.php 1 year ago button.php 1 year ago code.php 1 year ago contact-box.php 1 year ago contact-form.php 1 year ago custom-list.php 6 months ago divider.php 1 year ago dropcap.php 1 year ago facebook.php 1 year ago flickr.php 1 year ago gallery.php 1 year ago gmap.php 1 year ago highlight.php 1 year ago image.php 1 year ago instagram-feed.php 1 year ago latest-posts-slider.php 1 year ago popular-posts-widget.php 1 year ago products-grid.php 1 year ago quote.php 1 year ago recent-posts-grid-carousel.php 1 year ago recent-posts-land-style.php 1 year ago recent-posts-masonry.php 1 year ago recent-posts-tiles-carousel.php 1 year ago recent-posts-tiles.php 1 year ago recent-posts-timeline.php 1 year ago recent-posts-widget.php 1 year ago recent-products.php 1 year ago related-posts.php 8 years ago sample-element.php 1 year ago search.php 1 year ago socials-list.php 1 year ago staff.php 1 year ago tab-widget.php 1 year ago tabs.php 1 year ago testimonial.php 1 year ago text.php 1 year ago touch-slider.php 1 year ago video.php 1 year ago
recent-posts-land-style.php
648 lines
1 <?php
2 /**
3 * Code highlighter element
4 *
5 *
6 * @package Auxin
7 * @license LICENSE.txt
8 * @author averta
9 * @link http://phlox.pro/
10 * @copyright (c) 2010-2025 averta
11 */
12
13 function auxin_get_recent_posts_land_master_array( $master_array ) {
14
15 $categories = get_terms([
16 'taxonomy' => 'category',
17 'orderby' => 'count',
18 'hide_empty' => false,
19 ]);
20 $categories_list = array( ' ' => __('All Categories', 'auxin-elements' ) ) ;
21 foreach ( $categories as $key => $value ) {
22 $categories_list[$value->term_id] = $value->name;
23 }
24
25 // $tags = get_terms( 'post_tag', 'orderby=count&hide_empty=0' );
26 // $tags_list;
27 // foreach ($tags as $key => $value) {
28 // $tags_list["$value->term_id"] = $value->name;
29 // }
30
31
32 $master_array['aux_recent_posts_land_style'] = array(
33 'name' => __('Land Style Recent Posts', 'auxin-elements' ),
34 'auxin_output_callback' => 'auxin_widget_recent_posts_land_style_callback',
35 'base' => 'aux_recent_posts_land_style',
36 'description' => __('It adds recent posts in land style.', 'auxin-elements' ),
37 'class' => 'aux-widget-recent-posts-land',
38 'show_settings_on_create' => true,
39 'weight' => 1,
40 'is_widget' => false,
41 'is_shortcode' => true,
42 'category' => THEME_NAME,
43 'group' => '',
44 'admin_enqueue_js' => '',
45 'admin_enqueue_css' => '',
46 'front_enqueue_js' => '',
47 'front_enqueue_css' => '',
48 'icon' => 'aux-element aux-pb-icons-land',
49 'custom_markup' => '',
50 'js_view' => '',
51 'html_template' => '',
52 'deprecated' => '',
53 'content_element' => '',
54 'as_parent' => '',
55 'as_child' => '',
56 'params' => array(
57 array(
58 'heading' => __('Title','auxin-elements' ),
59 'description' => __('Recent post title, leave it empty if you don`t need title.', 'auxin-elements'),
60 'param_name' => 'title',
61 'type' => 'textfield',
62 'std' => '',
63 'value' => '',
64 'holder' => 'textfield',
65 'class' => 'title',
66 'admin_label' => false,
67 'dependency' => '',
68 'weight' => '',
69 'group' => '',
70 'edit_field_class' => ''
71 ),
72 array(
73 'heading' => __('Categories', 'auxin-elements'),
74 'description' => __('Specifies a category that you want to show posts from it.', 'auxin-elements' ),
75 'param_name' => 'cat',
76 'type' => 'aux_select2_multiple',
77 'def_value' => ' ',
78 'holder' => '',
79 'class' => 'cat',
80 'value' => $categories_list,
81 'admin_label' => false,
82 'dependency' => '',
83 'weight' => '',
84 'group' => __( 'Query', 'auxin-elements' ),
85 'edit_field_class' => ''
86 ),
87 array(
88 'heading' => __('Number of posts to show', 'auxin-elements'),
89 'description' => '',
90 'param_name' => 'num',
91 'type' => 'textfield',
92 'value' => '8',
93 'holder' => '',
94 'class' => 'num',
95 'admin_label' => false,
96 'dependency' => '',
97 'weight' => '',
98 'group' => __( 'Query', 'auxin-elements' ),
99 'edit_field_class' => ''
100 ),
101 array(
102 'heading' => __('Image aspect ratio', 'auxin-elements'),
103 'description' => '',
104 'param_name' => 'image_aspect_ratio',
105 'type' => 'dropdown',
106 'def_value' => '0.75',
107 'holder' => '',
108 'class' => 'order',
109 'value' =>array (
110 '0.75' => __('Horizontal 4:3' , 'auxin-elements'),
111 '0.56' => __('Horizontal 16:9', 'auxin-elements'),
112 '1.00' => __('Square 1:1' , 'auxin-elements'),
113 '1.33' => __('Vertical 3:4' , 'auxin-elements')
114 ),
115 'admin_label' => false,
116 'dependency' => '',
117 'weight' => '',
118 'group' => '',
119 'edit_field_class' => ''
120 ),
121 array(
122 'heading' => __('Exclude posts without media','auxin-elements' ),
123 'description' => '',
124 'param_name' => 'exclude_without_media',
125 'type' => 'aux_switch',
126 'value' => '0',
127 'class' => '',
128 'admin_label' => false,
129 'dependency' => '',
130 'weight' => '',
131 'group' => __( 'Query', 'auxin-elements' ),
132 'edit_field_class' => ''
133 ),
134 array(
135 'heading' => __('Exclude custom post formats','auxin-elements' ),
136 'description' => '',
137 'param_name' => 'exclude_custom_post_formats',
138 'type' => 'aux_switch',
139 'value' => '0',
140 'class' => '',
141 'admin_label' => false,
142 'dependency' => '',
143 'weight' => '',
144 'group' => __( 'Query', 'auxin-elements' ),
145 'edit_field_class' => ''
146 ),
147 array(
148 'heading' => __('Exclude quote and link post formats','auxin-elements' ),
149 'description' => '',
150 'param_name' => 'exclude_quote_link',
151 'type' => 'aux_switch',
152 'value' => '0',
153 'class' => '',
154 'admin_label' => false,
155 'dependency' => array(
156 'element' => 'exclude_custom_post_formats',
157 'value' => array('0', 'false')
158 ),
159 'weight' => '',
160 'group' => __( 'Query', 'auxin-elements' ),
161 'edit_field_class' => ''
162 ),
163 array(
164 'heading' => __('Order by', 'auxin-elements'),
165 'description' => '',
166 'param_name' => 'order_by',
167 'type' => 'dropdown',
168 'def_value' => 'date',
169 'holder' => '',
170 'class' => 'order_by',
171 'value' => array (
172 'date' => __('Date', 'auxin-elements'),
173 'menu_order date' => __('Menu Order', 'auxin-elements'),
174 'title' => __('Title', 'auxin-elements'),
175 'ID' => __('ID', 'auxin-elements'),
176 'rand' => __('Random', 'auxin-elements'),
177 'comment_count' => __('Comments', 'auxin-elements'),
178 'modified' => __('Date Modified', 'auxin-elements'),
179 'author' => __('Author', 'auxin-elements'),
180 'post__in' => __('Inserted Post IDs', 'auxin-elements')
181 ),
182 'admin_label' => false,
183 'dependency' => '',
184 'weight' => '',
185 'group' => __( 'Query', 'auxin-elements' ),
186 'edit_field_class' => ''
187 ),
188 array(
189 'heading' => __('Order', 'auxin-elements'),
190 'description' => '',
191 'param_name' => 'order',
192 'type' => 'dropdown',
193 'def_value' => 'DESC',
194 'holder' => '',
195 'class' => 'order',
196 'value' =>array (
197 'DESC' => __('Descending', 'auxin-elements'),
198 'ASC' => __('Ascending', 'auxin-elements'),
199 ),
200 'admin_label' => false,
201 'dependency' => '',
202 'weight' => '',
203 'group' => __( 'Query', 'auxin-elements' ),
204 'edit_field_class' => ''
205 ),
206 array(
207 'heading' => __('Only posts','auxin-elements' ),
208 'description' => __('If you intend to display ONLY specific posts, you should specify the posts here. You have to insert the post IDs that are separated by comma (eg. 53,34,87,25).', 'auxin-elements' ),
209 'param_name' => 'only_posts__in',
210 'type' => 'textfield',
211 'value' => '',
212 'holder' => '',
213 'class' => '',
214 'admin_label' => false,
215 'dependency' => '',
216 'weight' => '',
217 'group' => __( 'Query', 'auxin-elements' ),
218 'edit_field_class' => ''
219 ),
220 array(
221 'heading' => __('Include posts','auxin-elements' ),
222 'description' => __('If you intend to include additional posts, you should specify the posts here. You have to insert the Post IDs that are separated by comma (eg. 53,34,87,25)', 'auxin-elements' ),
223 'param_name' => 'include',
224 'type' => 'textfield',
225 'value' => '',
226 'holder' => '',
227 'class' => '',
228 'admin_label' => false,
229 'dependency' => '',
230 'weight' => '',
231 'group' => __( 'Query', 'auxin-elements' ),
232 'edit_field_class' => ''
233 ),
234 array(
235 'heading' => __('Exclude posts','auxin-elements' ),
236 'description' => __('If you intend to exclude specific posts from result, you should specify the posts here. You have to insert the Post IDs that are separated by comma (eg. 53,34,87,25)', 'auxin-elements' ),
237 'param_name' => 'exclude',
238 'type' => 'textfield',
239 'value' => '',
240 'holder' => '',
241 'class' => '',
242 'admin_label' => false,
243 'dependency' => '',
244 'weight' => '',
245 'group' => __( 'Query', 'auxin-elements' ),
246 'edit_field_class' => ''
247 ),
248 array(
249 'heading' => __('Start offset','auxin-elements' ),
250 'description' => __('Number of post to displace or pass over.', 'auxin-elements' ),
251 'param_name' => 'offset',
252 'type' => 'textfield',
253 'value' => '',
254 'holder' => '',
255 'class' => '',
256 'admin_label' => false,
257 'dependency' => '',
258 'weight' => '',
259 'group' => __( 'Query', 'auxin-elements' ),
260 'edit_field_class' => ''
261 ),
262 array(
263 'heading' => __('Display post media (image, video, etc)', 'auxin-elements' ),
264 'param_name' => 'show_media',
265 'type' => 'aux_switch',
266 'def_value' => '',
267 'value' => '1',
268 'holder' => '',
269 'class' => 'show_media',
270 'admin_label' => false,
271 'dependency' => '',
272 'weight' => '',
273 'group' => '',
274 'edit_field_class' => ''
275 ),
276 array(
277 'heading' => __('Display post title','auxin-elements' ),
278 'description' => '',
279 'param_name' => 'display_title',
280 'type' => 'aux_switch',
281 'value' => '1',
282 'class' => 'display_title',
283 'admin_label' => false,
284 'dependency' => '',
285 'weight' => '',
286 'group' => '',
287 'edit_field_class' => ''
288 ),
289 array(
290 'heading' => __('Display post meta','auxin-elements' ),
291 'description' => '',
292 'param_name' => 'show_info',
293 'type' => 'aux_switch',
294 'value' => '1',
295 'class' => '',
296 'admin_label' => false,
297 'weight' => '',
298 'group' => '',
299 'edit_field_class' => ''
300 ),
301 array(
302 'heading' => __('Display like button','auxin-elements' ),
303 'description' => sprintf(__('Enable it to display %s like button%s on gride template blog. Please note WP Ulike plugin needs to be activaited to use this option.', 'auxin-elements'), '<strong>', '</strong>'),
304 'param_name' => 'display_like',
305 'type' => 'aux_switch',
306 'value' => '1',
307 'holder' => '',
308 'class' => 'display_like',
309 'admin_label' => false,
310 'dependency' => '',
311 'weight' => '',
312 'group' => '',
313 'edit_field_class' => ''
314 ),
315 array(
316 'heading' => __('Load More Type','auxin-elements' ),
317 'description' => '',
318 'param_name' => 'loadmore_type',
319 'type' => 'aux_visual_select',
320 'value' => 'scroll',
321 'class' => 'loadmore_type',
322 'admin_label' => false,
323 'dependency' => '',
324 'weight' => '',
325 'group' => '' ,
326 'edit_field_class' => '',
327 'choices' => array(
328 '' => array(
329 'label' => __('None', 'auxin-elements' ),
330 'image' => AUXIN_URL . 'images/visual-select/load-more-none.svg'
331 ),
332 'scroll' => array(
333 'label' => __('Infinite Scroll', 'auxin-elements' ),
334 'image' => AUXIN_URL . 'images/visual-select/load-more-infinite.svg'
335 ),
336 'next' => array(
337 'label' => __('Next Button', 'auxin-elements' ),
338 'image' => AUXIN_URL . 'images/visual-select/load-more-button.svg'
339 ),
340 'next-prev' => array(
341 'label' => __('Next Prev', 'auxin-elements' ),
342 'image' => AUXIN_URL . 'images/visual-select/load-more-next-prev.svg'
343 )
344 )
345 ),
346 array(
347 'heading' => __('Excerpt length','auxin-elements' ),
348 'description' => __('Specify summary content in character.','auxin-elements' ),
349 'param_name' => 'excerpt_len',
350 'type' => 'textfield',
351 'value' => '160',
352 'holder' => '',
353 'class' => 'excerpt_len',
354 'admin_label' => false,
355 // @TODO: bcz of this dependency its value does not save on VC
356 'dependency' => array(
357 'element' => 'show_excerpt',
358 'value' => '1'
359 ),
360 'weight' => '',
361 'group' => '',
362 'edit_field_class' => ''
363 ),
364 array(
365 'heading' => __('Display author or read more', 'auxin-elements'),
366 'description' => __('Specifies whether to show author or read more on each post.', 'auxin-elements'),
367 'param_name' => 'author_or_readmore',
368 'type' => 'dropdown',
369 'def_value' => 'readmore',
370 'holder' => '',
371 'class' => 'author_or_readmore',
372 'value' =>array (
373 'readmore' => __('Read More', 'auxin-elements'),
374 'author' => __('Author Name', 'auxin-elements'),
375 ),
376 'admin_label' => false,
377 'dependency' => '',
378 'weight' => '',
379 'group' => '',
380 'edit_field_class' => ''
381 ),
382 array(
383 'heading' => __('Extra class name','auxin-elements' ),
384 'description' => __('If you wish to style particular content element differently, then use this field to add a class name and then refer to it in your css file.', 'auxin-elements' ),
385 'param_name' => 'extra_classes',
386 'type' => 'textfield',
387 'value' => '',
388 'def_value' => '',
389 'holder' => '',
390 'class' => 'extra_classes',
391 'admin_label' => false,
392 'dependency' => '',
393 'weight' => '',
394 'group' => '',
395 'edit_field_class' => ''
396 )
397 )
398 );
399
400 return $master_array;
401 }
402
403 add_filter( 'auxin_master_array_shortcodes', 'auxin_get_recent_posts_land_master_array', 10, 1 );
404
405
406
407
408 /**
409 * Element without loop and column
410 * The front-end output of this element is returned by the following function
411 *
412 * @param array $atts The array containing the parsed values from shortcode, it should be same as defined params above.
413 * @param string $shortcode_content The shorcode content
414 * @return string The output of element markup
415 */
416 function auxin_widget_recent_posts_land_style_callback( $atts, $shortcode_content = null ){
417
418 // Defining default attributes
419 $default_atts = array(
420 'title' => '', // header title
421 'cat' => ' ',
422 'num' => '8',
423 'only_posts__in' => '', // display only these post IDs. array or string comma separated
424 'include' => '', // include these post IDs in result too. array or string comma separated
425 'exclude' => '', // exclude these post IDs from result. array or string comma separated
426 'posts_per_page' => -1,
427 'paged' => '',
428 'offset' => '',
429 'order_by' => 'date',
430 'order' => 'DESC',
431 'size' => '',
432 'exclude_without_media' => 0,
433 'exclude_custom_post_formats' => 0,
434 'exclude_quote_link' => 0,
435 'exclude_post_formats_in' => array(), // the list od post formats to exclude
436 'show_media' => true,
437 'show_excerpt' => true,
438 'show_content' => true,
439 'excerpt_len' => '160',
440 'excerpt_length' => '',
441 'display_title' => true,
442 'display_like' => true,
443 'display_comments' => true,
444 'display_categories' => true,
445 'max_taxonomy_num' => '',
446 'show_info' => true,
447 'show_date' => true,
448 'author_or_readmore' => 'readmore',
449 'display_author_footer' => false,
450 'display_author_header' => true,
451 'image_aspect_ratio' => 0.75,
452 'tag' => '',
453 'taxonomy_name' => 'category',
454 'preloadable' => false,
455 'preload_preview' => true,
456 'preload_bgcolor' => '',
457
458 'extra_classes' => '',
459 'extra_column_classes' => '',
460 'custom_el_id' => '',
461
462 'template_part_file' => 'theme-parts/entry/post-column',
463 'extra_template_path' => '',
464
465 'universal_id' => '',
466 'reset_query' => true,
467 'use_wp_query' => false, // true to use the global wp_query, false to use internal custom query
468 'wp_query_args' => array(), // additional wp_query args
469 'loadmore_type' => '', // 'next' (more button), 'scroll', 'next-prev'
470 'loadmore_per_page' => '',
471 'base' => 'aux_recent_posts_land_style',
472 'base_class' => 'aux-widget-recent-posts-land'
473 );
474
475
476 $result = auxin_get_widget_scafold( $atts, $default_atts, $shortcode_content );
477 extract( $result['parsed_atts'] );
478
479 $acceptedTemplateFiles = apply_filters( 'auxin_recent_posts_land_style_accepted_template_files', [
480 'theme-parts/entry/post-column',
481 'theme-parts/entry/post-flip',
482 'theme-parts/entry/post-land',
483 'theme-parts/entry/post-tile',
484 'theme-parts/entry/post',
485 ]);
486
487 if ( ! in_array( $template_part_file, $acceptedTemplateFiles ) ) {
488 return;
489 }
490
491 $display_author_footer = auxin_is_true( $display_author_footer );
492 $display_author_header = auxin_is_true( $display_author_header );
493
494 // specify the post formats that should be excluded -------
495 $exclude_post_formats_in = (array) $exclude_post_formats_in;
496
497 if( $exclude_custom_post_formats ){
498 $exclude_post_formats_in = array_merge( $exclude_post_formats_in, array( 'aside', 'gallery', 'image', 'link', 'quote', 'video', 'audio' ) );
499 }
500 if( $exclude_quote_link ){
501 $exclude_post_formats_in[] = 'quote';
502 $exclude_post_formats_in[] = 'link';
503 }
504 $exclude_post_formats_in = array_unique( $exclude_post_formats_in );
505
506 // --------------
507
508
509 ob_start();
510
511 $tax_args = array();
512 if( ! empty( $cat ) && $cat != " " && ( ! is_array( $cat ) || ! in_array( " ", $cat ) ) ) {
513 $tax_args = array(
514 array(
515 'taxonomy' => $taxonomy_name,
516 'field' => 'term_id',
517 'terms' => ! is_array( $cat ) ? explode( ",", $cat ) : $cat
518 )
519 );
520 }
521
522 global $wp_query;
523
524 if( ! $use_wp_query ){
525
526 // create wp_query to get latest items -----------
527 $args = array(
528 'post_type' => 'post',
529 'orderby' => $order_by,
530 'order' => $order,
531 'offset' => $offset,
532 'paged' => $paged,
533 'tax_query' => $tax_args,
534 'post_status' => 'publish',
535 'posts_per_page' => $num,
536 'ignore_sticky_posts' => 1,
537 'include_posts__in' => $include, // include posts in this liat
538 'posts__not_in' => $exclude, // exclude posts in this list
539 'posts__in' => $only_posts__in, // only posts in this list
540
541 'exclude_without_media' => $exclude_without_media,
542 'exclude_post_formats_in' => $exclude_post_formats_in
543 );
544
545 // ---------------------------------------------------------------------
546
547 // add the additional query args if available
548 if( $wp_query_args ){
549 $args = wp_parse_args( $args, $wp_query_args );
550 }
551
552 // pass the args through the auxin query parser
553 $wp_query = new WP_Query( auxin_parse_query_args( $args ) );
554 }
555
556 // widget header ------------------------------
557 echo wp_kses_post( $result['widget_header'] );
558 echo wp_kses_post( $result['widget_title'] );
559
560
561 $phone_break_point = 767;
562 $tablet_break_point = 1025;
563
564 $show_comments = true; // shows comments icon
565 $post_counter = 0;
566 $column_class = 'aux-blog-land-style aux-ajax-view ' . $extra_column_classes;
567 $item_class = 'aux-block';
568
569 if( ! empty( $loadmore_type ) ) {
570 $item_class .= ' aux-ajax-item';
571 }
572
573 // automatically calculate the media size if was empty
574 if( empty( $size ) ){
575 $column_media_width = auxin_get_content_column_width( 2, 15, $content_width );
576 $size = array( 'width' => $column_media_width, 'height' => $column_media_width * $image_aspect_ratio );
577 }
578
579 // whether any result was found or not
580 $have_posts = $wp_query->have_posts();
581
582 if( $have_posts ){
583
584 echo ! $skip_wrappers ? sprintf( '<div data-element-id="%s" class="%s">', esc_attr( $universal_id ), esc_attr( $column_class ) ) : '';
585
586 while ( $wp_query->have_posts() ) {
587
588 $wp_query->the_post();
589 $post = $wp_query->post;
590 $post_vars = auxin_get_post_format_media(
591 $post,
592 array(
593 'request_from' => 'archive',
594 'media_width' => $phone_break_point,
595 'media_size' => $size,
596 'upscale_image' => true,
597 'preloadable' => $preloadable,
598 'preload_preview' => $preload_preview,
599 'preload_bgcolor' => $preload_bgcolor,
600 'image_sizes' => 'auto',
601 'srcset_sizes' => 'auto'
602 )
603 );
604
605 extract( $post_vars );
606
607 $the_format = get_post_format( $post );
608
609 $post_classes = 'aux-column-post-entry land-post-style';
610 $post_classes .= $has_attach ? '': ' aux-no-thumb';
611
612 printf( '<div class="%s post-%s">', esc_attr( $item_class ), esc_attr( $post->ID ) );
613 include auxin_get_template_file( $template_part_file, '', $extra_template_path );
614 echo '</div>';
615 }
616
617 if( ! $skip_wrappers ) {
618 // End tag for aux-ajax-view wrapper
619 echo '</div>';
620 // Execute load more functionality
621 if( $wp_query->found_posts > $loadmore_per_page ) {
622 echo auxin_get_load_more_controller( $loadmore_type );
623 }
624
625 } else {
626 // Get post counter in the query
627 echo '<span class="aux-post-count hidden">'. esc_html( $wp_query->post_count ) .'</span>';
628 echo '<span class="aux-all-posts-count hidden">'. esc_html( $wp_query->found_posts ) .'</span>';
629 }
630
631 }
632
633 if( $reset_query ){
634 wp_reset_query();
635 }
636
637 // return false if no result found
638 if( ! $have_posts ){
639 ob_get_clean();
640 return false;
641 }
642
643 // widget footer ------------------------------
644 echo wp_kses_post( $result['widget_footer'] );
645
646 return ob_get_clean();
647 }
648