Shortcodes and extra features for Phlox theme - Version 1.5.2

Version Description

Download this release

Release Info

Developer averta
Plugin Icon 128x128 Shortcodes and extra features for Phlox theme
Version 1.5.2
Comparing to
See all releases

Code changes from version 1.5.0 to 1.5.2

Files changed (43) hide show
  1. README.txt +6 -1
  2. admin/includes/admin-hooks.php +15 -19
  3. auxin-elements.php +2 -6
  4. includes/classes/class-auxin-widget-shortcode-map.php +4 -0
  5. includes/classes/class-auxin-widget.php +20 -38
  6. includes/define.php +1 -1
  7. includes/elements/about-widget.php +1 -1
  8. includes/elements/accordion.php +1 -1
  9. includes/elements/audio.php +1 -1
  10. includes/elements/before-after.php +1 -1
  11. includes/elements/button.php +1 -1
  12. includes/elements/code.php +1 -1
  13. includes/elements/contact-box.php +1 -1
  14. includes/elements/contact-form.php +1 -1
  15. includes/elements/divider.php +1 -1
  16. includes/elements/dropcap.php +1 -1
  17. includes/elements/facebook.php +1 -1
  18. includes/elements/flickr.php +1 -1
  19. includes/elements/gallery.php +1 -1
  20. includes/elements/gmap.php +1 -1
  21. includes/elements/highlight.php +1 -1
  22. includes/elements/image.php +1 -1
  23. includes/elements/instagram-feed.php +1 -1
  24. includes/elements/latest-posts-slider.php +4 -4
  25. includes/elements/popular-posts-widget.php +1 -1
  26. includes/elements/quote.php +1 -1
  27. includes/elements/recent-posts-grid-carousel.php +57 -67
  28. includes/elements/recent-posts-land-style.php +63 -6
  29. includes/elements/recent-posts-masonry.php +68 -62
  30. includes/elements/recent-posts-tiles.php +74 -22
  31. includes/elements/recent-posts-timeline.php +65 -10
  32. includes/elements/recent-posts-widget.php +1 -1
  33. includes/elements/search.php +1 -1
  34. includes/elements/socials-list.php +1 -1
  35. includes/elements/staff.php +654 -0
  36. includes/elements/tabs.php +1 -1
  37. includes/elements/text.php +1 -1
  38. includes/elements/touch-slider.php +1 -1
  39. includes/elements/video.php +1 -1
  40. includes/general-functions.php +446 -2
  41. includes/general-hooks.php +10 -0
  42. includes/index.php +1 -0
  43. public/includes/frontend-ajax.php +30 -32
README.txt CHANGED
@@ -4,9 +4,10 @@ Donate link: http://averta.net/
4
  License: GPLv3
5
  License URI: http://www.gnu.org/licenses/gpl.html
6
  Tags: banner SEO, shortcode, page-builder, siteorigin, auxin, phlox, averta, framework, widget, element, fullwidth, masonry, timeline
 
7
  Requires at least: 4.6
8
  Tested up to: 4.8.1
9
- Stable tag: 1.5.0
10
  License: GPLv3
11
  License URI: http://www.gnu.org/licenses/gpl.html
12
 
@@ -140,6 +141,10 @@ Bugs can be reported in our [support forums](http://wordpress.org/tags/auxin-ele
140
 
141
  == Changelog ==
142
 
 
 
 
 
143
  = Version 1.5.0 / (29.08.2017) =
144
  - [Fix]: Addressed a conflict with popup-maker plugin.
145
  - [Fix]: Some minor bugs in Text Element fixed.
4
  License: GPLv3
5
  License URI: http://www.gnu.org/licenses/gpl.html
6
  Tags: banner SEO, shortcode, page-builder, siteorigin, auxin, phlox, averta, framework, widget, element, fullwidth, masonry, timeline
7
+ Requires PHP: 5.3
8
  Requires at least: 4.6
9
  Tested up to: 4.8.1
10
+ Stable tag: 1.5.2
11
  License: GPLv3
12
  License URI: http://www.gnu.org/licenses/gpl.html
13
 
141
 
142
  == Changelog ==
143
 
144
+ = Version 1.5.2 / (18.09.2017) =
145
+ - [New]: Load more option and button for blog elements.
146
+ - [Fix]: Fixing the category field option in blog elements.
147
+
148
  = Version 1.5.0 / (29.08.2017) =
149
  - [Fix]: Addressed a conflict with popup-maker plugin.
150
  - [Fix]: Some minor bugs in Text Element fixed.
admin/includes/admin-hooks.php CHANGED
@@ -54,45 +54,41 @@ add_action('admin_enqueue_scripts', 'auxin_register_mce_buttons_style');
54
 
55
  function auxin_welcome_page_display_section_demos(){
56
  // all the demos information should add into this array
57
- $data = get_transient( 'auxin_get_demo' );
58
 
59
- if ( empty( $data ) ){
60
 
61
- $request = wp_remote_get( 'http://api.averta.net/products/themes/demos' );
62
 
63
  if( is_wp_error( $request ) ) {
64
-
65
  return false;
66
-
67
  }
68
 
69
  $body = wp_remote_retrieve_body( $request );
70
- $data = json_decode($body);
71
-
72
- set_transient( 'auxin_get_demo', $data, DAY_IN_SECONDS );
73
 
 
74
  }
75
 
76
  ?>
77
- <h2 class="aux-featur"><?php _e('Choose the demo you want.', 'auxin-elements'); ?></h2>
78
- <h4 class="aux-featur demos-subtitle"><?php _e('Please note that, it is recommended to import a demo on a clean WordPress installation.', 'auxin-elements'); ?></h4>
79
  <div class="changelog feature-section three-col">
80
- <?php foreach ($data as $demo) {
81
- ?>
82
- <div class="col" id="<?php echo $demo->site_id ?>">
83
- <img class="demos-img" src="<?php echo $demo->thumbnail ; ?>" alt="<?php echo $demo->title ; ?>">
84
- <h3><?php echo $demo->title ; ?></h3>
85
  <p><?php echo $demo->excerpt ; ?></p>
86
 
87
- <a href="<?php echo $demo->url ; ?>" class="button button-primary aux-button" target="_blank"><?php _e('Preview', 'auxin-elements'); ?></a>
88
  <a href="" class="button button-primary aux-button import-demo">
89
  <?php _e( 'Import Demo', 'auxin-elements' ); ?>
90
  </a>
91
  </div>
92
- <?php }?>
93
-
94
- </div> <?php
95
 
 
 
96
  }
97
 
98
  function auxin_welcome_add_section_demos( $sections ){
54
 
55
  function auxin_welcome_page_display_section_demos(){
56
  // all the demos information should add into this array
57
+ $demo_list = get_transient( 'auxin_'. THEME_ID .'_demo_list' );
58
 
59
+ if ( empty( $demo_list ) ){
60
 
61
+ $request = wp_remote_get( 'http://averta.net/phlox/wordpress-theme/demo/wp-content/list.json' );
62
 
63
  if( is_wp_error( $request ) ) {
 
64
  return false;
 
65
  }
66
 
67
  $body = wp_remote_retrieve_body( $request );
68
+ $demo_list = json_decode( $body );
 
 
69
 
70
+ set_transient( 'auxin_'. THEME_ID .'_demo_list', $demo_list, DAY_IN_SECONDS );
71
  }
72
 
73
  ?>
74
+ <h2 class="aux-featur"><?php esc_html_e( 'Choose the demo you want.', 'auxin-elements' ); ?></h2>
75
+ <h4 class="aux-featur demos-subtitle"><?php esc_html_e('Please note that, it is recommended to import a demo on a clean WordPress installation.', 'auxin-elements'); ?></h4>
76
  <div class="changelog feature-section three-col">
77
+ <?php foreach ( $demo_list as $demo ) { ?>
78
+ <div class="col" id="<?php echo esc_attr( $demo->site_id ); ?>">
79
+ <img class="demos-img" src="<?php echo esc_url( $demo->thumbnail ) ; ?>" alt="<?php echo esc_attr( $demo->title ); ?>">
80
+ <h3><?php echo esc_html( $demo->title ); ?></h3>
 
81
  <p><?php echo $demo->excerpt ; ?></p>
82
 
83
+ <a href="<?php echo esc_url( $demo->url ); ?>" class="button button-primary aux-button" target="_blank"><?php esc_html_e('Preview', 'auxin-elements'); ?></a>
84
  <a href="" class="button button-primary aux-button import-demo">
85
  <?php _e( 'Import Demo', 'auxin-elements' ); ?>
86
  </a>
87
  </div>
88
+ <?php } ?>
 
 
89
 
90
+ </div>
91
+ <?php
92
  }
93
 
94
  function auxin_welcome_add_section_demos( $sections ){
auxin-elements.php CHANGED
@@ -12,7 +12,7 @@
12
  * Plugin Name: Phlox Core Elements
13
  * Plugin URI: https://wordpress.org/plugins/auxin-elements/
14
  * Description: Powerful and comprehensive plugin that extends the functionality of Phlox theme by adding new shortcodes, widgets and options
15
- * Version: 1.5.0
16
  * Author: averta
17
  * Author URI: http://averta.net
18
  * Text Domain: auxin-elements
@@ -68,16 +68,12 @@ if( is_admin() || false === get_transient( 'auxels_plugin_requirements_check' )
68
  'themes' => array(
69
  array(
70
  'name' => __('Phlox', 'auxin-elements'), // The theme name.
71
- 'version' => '1.6.25', // E.g. 1.0.0. If set, the active theme must be this version or higher.
72
  'is_callable' => '', // If set, this callable will be be checked for availability to determine if a theme is active.
73
  'file_exists' => get_template_directory() . '/auxin/auxin-include/auxin.php' // If set, this file will be checked for availability to determine if a theme is active.
74
  )
75
  ),
76
 
77
- 'php' => array(
78
- 'version' => '5.3.0' // The minimum PHP version for this plugin, otherwise, throw a notice
79
- ),
80
-
81
  'config' => array(
82
  'plugin_name' => __('Phlox Core Elements', 'auxin-elements'), // Current plugin name.
83
  'plugin_basename' => plugin_basename( __FILE__ ),
12
  * Plugin Name: Phlox Core Elements
13
  * Plugin URI: https://wordpress.org/plugins/auxin-elements/
14
  * Description: Powerful and comprehensive plugin that extends the functionality of Phlox theme by adding new shortcodes, widgets and options
15
+ * Version: 1.5.2
16
  * Author: averta
17
  * Author URI: http://averta.net
18
  * Text Domain: auxin-elements
68
  'themes' => array(
69
  array(
70
  'name' => __('Phlox', 'auxin-elements'), // The theme name.
71
+ 'version' => '1.7.1', // E.g. 1.0.0. If set, the active theme must be this version or higher.
72
  'is_callable' => '', // If set, this callable will be be checked for availability to determine if a theme is active.
73
  'file_exists' => get_template_directory() . '/auxin/auxin-include/auxin.php' // If set, this file will be checked for availability to determine if a theme is active.
74
  )
75
  ),
76
 
 
 
 
 
77
  'config' => array(
78
  'plugin_name' => __('Phlox Core Elements', 'auxin-elements'), // Current plugin name.
79
  'plugin_basename' => plugin_basename( __FILE__ ),
includes/classes/class-auxin-widget-shortcode-map.php CHANGED
@@ -238,6 +238,10 @@ class Auxin_Widget_Shortcode_Map {
238
  if( isset( $param['dependency'] ) ) {
239
  $widget_params['dependency'] = $param['dependency'];
240
  }
 
 
 
 
241
  // TODO: It shoould convert to array an array when dependency js writes
242
  // $widget_params['dependency'] = array( $param['dependency'] );
243
 
238
  if( isset( $param['dependency'] ) ) {
239
  $widget_params['dependency'] = $param['dependency'];
240
  }
241
+ // special param for aux_taxonomy field type
242
+ if( isset( $param['taxonomy'] ) ) {
243
+ $widget_params['taxonomy'] = $param['taxonomy'];
244
+ }
245
  // TODO: It shoould convert to array an array when dependency js writes
246
  // $widget_params['dependency'] = array( $param['dependency'] );
247
 
includes/classes/class-auxin-widget.php CHANGED
@@ -21,7 +21,7 @@ if( ! class_exists( 'Auxin_Widget' ) ) :
21
 
22
  class Auxin_Widget extends WP_Widget {
23
 
24
- private $defaults = array();
25
  public $fields = array();
26
 
27
  public $widget_fun_name;
@@ -108,6 +108,7 @@ class Auxin_Widget extends WP_Widget {
108
  'hide_empty' => true
109
  ));
110
 
 
111
  $categories_list = array( ' ' => __('All Categories', 'auxin-elements' ) ) ;
112
  foreach ( $categories as $key => $value ) {
113
  $categories_list[ $value->term_id ] = $value->name;
@@ -122,7 +123,7 @@ class Auxin_Widget extends WP_Widget {
122
  echo '<div class="aux-element-field aux-multiple-selector ">',
123
  '<label for="'.$this->get_field_id($id).'" >'.$field["name"].'</label>',
124
  '<select multiple="multiple" name="' . $this->get_field_name($id) . '" id="' . $this->get_field_name($id) . '" class="aux-orig-select2 aux-admin-select2 aux-select2-multiple">';
125
- $output .= '<option value="">' . __('Choose ..', 'auxin-elements') . '</option>';
126
 
127
  foreach ( $categories_list as $key => $value ) {
128
  printf(
@@ -193,14 +194,19 @@ class Auxin_Widget extends WP_Widget {
193
 
194
  case 'dropdown':
195
  case 'select':
 
 
 
 
 
196
  echo '<div class="aux-element-field aux-dropdown">',
197
  '<label for="'.$this->get_field_id( $id ).'" >'. $field['name']. '</label>',
198
- '<select name="' .$this->get_field_name( $id ) . '" id="' . $this->get_field_id( $id ) . '" value="' . $instance[$id] . '" >';
199
  foreach ( $field['options'] as $key => $value ) {
200
- echo '<option value="'.$key.'" '.selected( $instance[$id], $key, false ).' >'. $value. '</option>';
201
  }
202
-
203
  echo '</select>';
 
204
  if ( $field["description"] ) {
205
  echo '<p class="option-description">' . $field["description"] . '</p>';
206
  }
@@ -209,12 +215,17 @@ class Auxin_Widget extends WP_Widget {
209
 
210
  // Select2 single
211
  case 'aux_select2_single' :
 
 
 
 
 
212
  echo '<div class="aux-element-field aux-multiple-selector ">',
213
  '<label for="'.$this->get_field_id($id).'" >'.$field["name"].'</label>',
214
  '<div class="section-row-right" >' ,
215
- '<select name="'.$this->get_field_name($id).'" id="'.$this->get_field_id($id).'" class="aux-orig-select2 aux-admin-select2 aux-select2-single" data-value="' . $instance[$id] . '" value="' . $instance[$id] . '" style="width:150px" >';
216
  foreach ( $field['options'] as $key => $value ) {
217
- echo '<option value="'.$key.'" '.selected( $instance[$id], $key, false ).' >'. $value. '</option>';
218
  }
219
  echo '</select></div>';
220
  if ( $field["description"] ) {
@@ -227,9 +238,7 @@ class Auxin_Widget extends WP_Widget {
227
  case 'aux_select2_multiple' :
228
 
229
  if( gettype( $instance[ $id ] ) ==="string" ) {
230
-
231
  $select = explode( ',', $instance[ $id ] );
232
-
233
  }
234
 
235
  $output = '';
@@ -237,10 +246,8 @@ class Auxin_Widget extends WP_Widget {
237
  $output .= '<select multiple="multiple" name="' . esc_sql( $field['id'] ) . '" style="width:100%" ' . ' class="wpb-multiselect wpb_vc_param_value aux-select2-multiple ' . esc_sql( $field['id'] ) . ' ' . $field['type'] . '_field" '. '>';
238
 
239
  foreach ( $field['options'] as $key => $value ) {
240
-
241
  $active_attr = in_array( $key, $select) ? 'selected="selected"' : '';
242
  $output .= sprintf( '<option value="%s" %s >%s</option>', $key, $active_attr, $value );
243
-
244
  }
245
 
246
  $output .= '</select>';
@@ -249,7 +256,7 @@ class Auxin_Widget extends WP_Widget {
249
 
250
  $output .= '<p class="option-description">' . $field["description"] . '</p>';
251
  }
252
-
253
  $output .= '</div>' ;
254
  echo $output;
255
 
@@ -259,7 +266,7 @@ class Auxin_Widget extends WP_Widget {
259
  $output = '<div class="aux-element-field aux-visual-selector">';
260
  $output .= '<label for="'.$this->get_field_id($id).'" >'.$field["name"].'</label>';
261
  $output .= '<select class="meta-select visual-select-wrapper" name="' . $this->get_field_name( $id ) . '" id="' . $this->get_field_id( $id ) . '" value="' . $instance[$id] . '" >';
262
- // TODO: I don't know why $instance[$id] is null or empty inside below loop
263
  $tmp_instance_id = $instance[$id];
264
  foreach ( $field['choices'] as $id => $option_info ) {
265
  $active_attr = ( $tmp_instance_id == $id ) ? ' selected ' : "";
@@ -433,33 +440,8 @@ class Auxin_Widget extends WP_Widget {
433
  unset( $depend['callback'] );
434
 
435
  $field_dependencies[ $depend['element'] ] = array( 'value' => (array)$depend['value'] );
436
-
437
- // if( isset( $depend['callback'] ) ) {
438
- // $field_dependencies[ $depend['element'] ]['callback'] = $depend['callback'];
439
- // }
440
  }
441
 
442
-
443
- /* if there was a list of dependencies
444
-
445
- $dependencies = (array) $field['dependency'];
446
-
447
- foreach ( $dependencies as $depend_id => $depend ) {
448
-
449
- if( 'relation' === $depend_id ) {
450
- $field_dependencies[ $depend_id ] = $depend;
451
- continue;
452
- }
453
-
454
- if( ! isset( $depend['element'] ) || ! ( isset( $depend['value'] ) && ! empty( $depend['value'] ) ) ){ continue; }
455
-
456
- $field_dependencies[ $depend['element'] ] = array( 'value' => (array)$depend['value'] );
457
-
458
- if( isset( $depend['callback'] ) ) {
459
- $field_dependencies[ $depend['element'] ]['callback'] = $depend['callback'];
460
- }
461
- }
462
- */
463
  }
464
 
465
  if( $field_dependencies ){
21
 
22
  class Auxin_Widget extends WP_Widget {
23
 
24
+ private $defaults = array();
25
  public $fields = array();
26
 
27
  public $widget_fun_name;
108
  'hide_empty' => true
109
  ));
110
 
111
+
112
  $categories_list = array( ' ' => __('All Categories', 'auxin-elements' ) ) ;
113
  foreach ( $categories as $key => $value ) {
114
  $categories_list[ $value->term_id ] = $value->name;
123
  echo '<div class="aux-element-field aux-multiple-selector ">',
124
  '<label for="'.$this->get_field_id($id).'" >'.$field["name"].'</label>',
125
  '<select multiple="multiple" name="' . $this->get_field_name($id) . '" id="' . $this->get_field_name($id) . '" class="aux-orig-select2 aux-admin-select2 aux-select2-multiple">';
126
+ echo '<option value="">' . __('Choose ..', 'auxin-elements') . '</option>';
127
 
128
  foreach ( $categories_list as $key => $value ) {
129
  printf(
194
 
195
  case 'dropdown':
196
  case 'select':
197
+ if( is_array( $instance[$id] ) ){
198
+ $current_value = ! empty( $instance['def_value'] ) ? $instance['def_value'] : array_keys( $instance[ $id ] )[0];
199
+ } else {
200
+ $current_value = $instance[ $id ];
201
+ }
202
  echo '<div class="aux-element-field aux-dropdown">',
203
  '<label for="'.$this->get_field_id( $id ).'" >'. $field['name']. '</label>',
204
+ '<select name="' .$this->get_field_name( $id ) . '" id="' . $this->get_field_id( $id ) . '" value="' . $current_value . '" >';
205
  foreach ( $field['options'] as $key => $value ) {
206
+ printf( '<option value="%s" %s >%s</option>', $key, selected( $current_value, $key, false ), $value );
207
  }
 
208
  echo '</select>';
209
+
210
  if ( $field["description"] ) {
211
  echo '<p class="option-description">' . $field["description"] . '</p>';
212
  }
215
 
216
  // Select2 single
217
  case 'aux_select2_single' :
218
+ if( is_array( $instance[$id] ) ){
219
+ $current_value = ! empty( $instance['def_value'] ) ? $instance['def_value'] : array_keys( $instance[ $id ] )[0];
220
+ } else {
221
+ $current_value = $instance[ $id ];
222
+ }
223
  echo '<div class="aux-element-field aux-multiple-selector ">',
224
  '<label for="'.$this->get_field_id($id).'" >'.$field["name"].'</label>',
225
  '<div class="section-row-right" >' ,
226
+ '<select name="'.$this->get_field_name($id).'" id="'.$this->get_field_id($id).'" class="aux-orig-select2 aux-admin-select2 aux-select2-single" data-value="'.$current_value.'" value="'. $current_value .'" style="width:150px" >';
227
  foreach ( $field['options'] as $key => $value ) {
228
+ printf( '<option value="%s" %s >%s</option>', $key, selected( $current_value, $key, false ), $value );
229
  }
230
  echo '</select></div>';
231
  if ( $field["description"] ) {
238
  case 'aux_select2_multiple' :
239
 
240
  if( gettype( $instance[ $id ] ) ==="string" ) {
 
241
  $select = explode( ',', $instance[ $id ] );
 
242
  }
243
 
244
  $output = '';
246
  $output .= '<select multiple="multiple" name="' . esc_sql( $field['id'] ) . '" style="width:100%" ' . ' class="wpb-multiselect wpb_vc_param_value aux-select2-multiple ' . esc_sql( $field['id'] ) . ' ' . $field['type'] . '_field" '. '>';
247
 
248
  foreach ( $field['options'] as $key => $value ) {
 
249
  $active_attr = in_array( $key, $select) ? 'selected="selected"' : '';
250
  $output .= sprintf( '<option value="%s" %s >%s</option>', $key, $active_attr, $value );
 
251
  }
252
 
253
  $output .= '</select>';
256
 
257
  $output .= '<p class="option-description">' . $field["description"] . '</p>';
258
  }
259
+
260
  $output .= '</div>' ;
261
  echo $output;
262
 
266
  $output = '<div class="aux-element-field aux-visual-selector">';
267
  $output .= '<label for="'.$this->get_field_id($id).'" >'.$field["name"].'</label>';
268
  $output .= '<select class="meta-select visual-select-wrapper" name="' . $this->get_field_name( $id ) . '" id="' . $this->get_field_id( $id ) . '" value="' . $instance[$id] . '" >';
269
+
270
  $tmp_instance_id = $instance[$id];
271
  foreach ( $field['choices'] as $id => $option_info ) {
272
  $active_attr = ( $tmp_instance_id == $id ) ? ' selected ' : "";
440
  unset( $depend['callback'] );
441
 
442
  $field_dependencies[ $depend['element'] ] = array( 'value' => (array)$depend['value'] );
 
 
 
 
443
  }
444
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
445
  }
446
 
447
  if( $field_dependencies ){
includes/define.php CHANGED
@@ -12,7 +12,7 @@ if( ! defined( 'THEME_NAME' ) ){
12
  }
13
 
14
 
15
- define( 'AUXELS_VERSION' , '1.5.0' );
16
 
17
  define( 'AUXELS_SLUG' , 'auxin-elements' );
18
 
12
  }
13
 
14
 
15
+ define( 'AUXELS_VERSION' , '1.5.2' );
16
 
17
  define( 'AUXELS_SLUG' , 'auxin-elements' );
18
 
includes/elements/about-widget.php CHANGED
@@ -13,7 +13,7 @@
13
  function get_auxin_about_widget( $master_array ) {
14
 
15
  $master_array['aux_about_widget'] = array(
16
- 'name' => __("[Phlox] About Author", 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_about_callback',
18
  'base' => 'aux_about_widget',
19
  'description' => __('It adds an about author element.', 'auxin-elements' ),
13
  function get_auxin_about_widget( $master_array ) {
14
 
15
  $master_array['aux_about_widget'] = array(
16
+ 'name' => __("About Author", 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_about_callback',
18
  'base' => 'aux_about_widget',
19
  'description' => __('It adds an about author element.', 'auxin-elements' ),
includes/elements/accordion.php CHANGED
@@ -13,7 +13,7 @@
13
  function auxin_get_new_accordion_master_array( $master_array ) {
14
 
15
  $master_array['aux_accordion'] = array(
16
- 'name' => __('[Phlox] Accordion ', 'auxin-elements'),
17
  'auxin_output_callback' => 'auxin_widget_accordion_callback',
18
  'base' => 'aux_accordion',
19
  'description' => __('Collapsible content', 'auxin-elements'),
13
  function auxin_get_new_accordion_master_array( $master_array ) {
14
 
15
  $master_array['aux_accordion'] = array(
16
+ 'name' => __('Accordion ', 'auxin-elements'),
17
  'auxin_output_callback' => 'auxin_widget_accordion_callback',
18
  'base' => 'aux_accordion',
19
  'description' => __('Collapsible content', 'auxin-elements'),
includes/elements/audio.php CHANGED
@@ -12,7 +12,7 @@
12
  function auxin_get_audio_master_array( $master_array ) {
13
 
14
  $master_array['aux_audio'] = array(
15
- 'name' => __("[Phlox] Audio", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_audio_callback',
17
  'base' => 'aux_audio',
18
  'description' => __('Audio player', 'auxin-elements' ),
12
  function auxin_get_audio_master_array( $master_array ) {
13
 
14
  $master_array['aux_audio'] = array(
15
+ 'name' => __("Audio", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_audio_callback',
17
  'base' => 'aux_audio',
18
  'description' => __('Audio player', 'auxin-elements' ),
includes/elements/before-after.php CHANGED
@@ -12,7 +12,7 @@
12
  function auxin_get_before_after_master_array( $master_array ) {
13
 
14
  $master_array['aux_before_after'] = array(
15
- 'name' => __("[Phlox] Before After Slider", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_before_after_callback',
17
  'base' => 'aux_before_after',
18
  'description' => __('Before after comparison slider.', 'auxin-elements' ),
12
  function auxin_get_before_after_master_array( $master_array ) {
13
 
14
  $master_array['aux_before_after'] = array(
15
+ 'name' => __("Before After Slider", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_before_after_callback',
17
  'base' => 'aux_before_after',
18
  'description' => __('Before after comparison slider.', 'auxin-elements' ),
includes/elements/button.php CHANGED
@@ -13,7 +13,7 @@
13
  function auxin_get_button_master_array( $master_array ) {
14
 
15
  $master_array['aux_button'] = array(
16
- 'name' => __("[Phlox] Button", 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_button_callback',
18
  'base' => 'aux_button',
19
  'description' => __('It adds a button element.', 'auxin-elements' ),
13
  function auxin_get_button_master_array( $master_array ) {
14
 
15
  $master_array['aux_button'] = array(
16
+ 'name' => __("Button", 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_button_callback',
18
  'base' => 'aux_button',
19
  'description' => __('It adds a button element.', 'auxin-elements' ),
includes/elements/code.php CHANGED
@@ -13,7 +13,7 @@
13
  function auxin_get_code_master_array( $master_array ) {
14
 
15
  $master_array['aux_code'] = array(
16
- 'name' => __('[Phlox] Code', 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_code_callback',
18
  'base' => 'aux_code',
19
  'description' => __('It adds a code element.', 'auxin-elements' ),
13
  function auxin_get_code_master_array( $master_array ) {
14
 
15
  $master_array['aux_code'] = array(
16
+ 'name' => __('Code', 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_code_callback',
18
  'base' => 'aux_code',
19
  'description' => __('It adds a code element.', 'auxin-elements' ),
includes/elements/contact-box.php CHANGED
@@ -13,7 +13,7 @@
13
  function get_auxin_contact_box( $master_array ) {
14
 
15
  $master_array['aux_contact_box'] = array(
16
- 'name' => __("[Phlox] Contact Box", 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_contact_box',
18
  'base' => 'aux_contact_box',
19
  'description' => __('It adds a contact box element.', 'auxin-elements'),
13
  function get_auxin_contact_box( $master_array ) {
14
 
15
  $master_array['aux_contact_box'] = array(
16
+ 'name' => __("Contact Box", 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_contact_box',
18
  'base' => 'aux_contact_box',
19
  'description' => __('It adds a contact box element.', 'auxin-elements'),
includes/elements/contact-form.php CHANGED
@@ -13,7 +13,7 @@
13
  function auxin_get_contact_form_master_array( $master_array ) {
14
 
15
  $master_array['aux_contact_form'] = array(
16
- 'name' => __('[Phlox] Contact Form', 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_contact_form_callback',
18
  'base' => 'aux_contact_form',
19
  'description' => __('It adds a contact form element.', 'auxin-elements' ),
13
  function auxin_get_contact_form_master_array( $master_array ) {
14
 
15
  $master_array['aux_contact_form'] = array(
16
+ 'name' => __('Contact Form', 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_contact_form_callback',
18
  'base' => 'aux_contact_form',
19
  'description' => __('It adds a contact form element.', 'auxin-elements' ),
includes/elements/divider.php CHANGED
@@ -13,7 +13,7 @@
13
  function auxin_get_divider_master_array( $master_array ) {
14
 
15
  $master_array['aux_divider'] = array(
16
- 'name' => __('[Phlox] Divider', 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_divider_callback',
18
  'base' => 'aux_divider',
19
  'description' => __('Horizontal seperator', 'auxin-elements'),
13
  function auxin_get_divider_master_array( $master_array ) {
14
 
15
  $master_array['aux_divider'] = array(
16
+ 'name' => __('Divider', 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_divider_callback',
18
  'base' => 'aux_divider',
19
  'description' => __('Horizontal seperator', 'auxin-elements'),
includes/elements/dropcap.php CHANGED
@@ -12,7 +12,7 @@
12
  function auxin_get_dropcap_master_array( $master_array ) {
13
 
14
  $master_array['aux_dropcap'] = array(
15
- 'name' => __("[Phlox] Dropcap", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_dropcap_callback',
17
  'base' => 'aux_dropcap',
18
  'description' => __('Big styled character at the beginning of paragraph', 'auxin-elements' ),
12
  function auxin_get_dropcap_master_array( $master_array ) {
13
 
14
  $master_array['aux_dropcap'] = array(
15
+ 'name' => __("Dropcap", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_dropcap_callback',
17
  'base' => 'aux_dropcap',
18
  'description' => __('Big styled character at the beginning of paragraph', 'auxin-elements' ),
includes/elements/facebook.php CHANGED
@@ -13,7 +13,7 @@
13
  function auxin_get_facebook_master_array( $master_array ) {
14
 
15
  $master_array['aux_facebook'] = array(
16
- 'name' => __('[Phlox] Custom Facebook Feed', 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_facebook_callback',
18
  'base' => 'aux_facebook',
19
  'description' => __('It uses Custom Facebook Feed plugin.', 'auxin-elements'),
13
  function auxin_get_facebook_master_array( $master_array ) {
14
 
15
  $master_array['aux_facebook'] = array(
16
+ 'name' => __('Custom Facebook Feed', 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_facebook_callback',
18
  'base' => 'aux_facebook',
19
  'description' => __('It uses Custom Facebook Feed plugin.', 'auxin-elements'),
includes/elements/flickr.php CHANGED
@@ -13,7 +13,7 @@
13
  function auxin_get_flickr_master_array( $master_array ) {
14
 
15
  $master_array['aux_flickr'] = array(
16
- 'name' => __('[Phlox] Flickr Justified Gallery', 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_flickr_callback',
18
  'base' => 'aux_flickr',
19
  'description' => __('It uses Flickr Justified Gallery plugin.', 'auxin-elements'),
13
  function auxin_get_flickr_master_array( $master_array ) {
14
 
15
  $master_array['aux_flickr'] = array(
16
+ 'name' => __('Flickr Justified Gallery', 'auxin-elements' ),
17
  'auxin_output_callback' => 'auxin_widget_flickr_callback',
18
  'base' => 'aux_flickr',
19
  'description' => __('It uses Flickr Justified Gallery plugin.', 'auxin-elements'),
includes/elements/gallery.php CHANGED
@@ -12,7 +12,7 @@
12
  function auxin_get_gallery_master_array( $master_array ) {
13
 
14
  $master_array['aux_gallery'] = array(
15
- 'name' => __('[Phlox] Gallery', 'auxin-elements'),
16
  'auxin_output_callback' => 'auxin_widget_gallery_callback',
17
  'base' => 'aux_gallery',
18
  'description' => __('Filterable and grid gallery with lightbox', 'auxin-elements'),
12
  function auxin_get_gallery_master_array( $master_array ) {
13
 
14
  $master_array['aux_gallery'] = array(
15
+ 'name' => __('Gallery', 'auxin-elements'),
16
  'auxin_output_callback' => 'auxin_widget_gallery_callback',
17
  'base' => 'aux_gallery',
18
  'description' => __('Filterable and grid gallery with lightbox', 'auxin-elements'),
includes/elements/gmap.php CHANGED
@@ -12,7 +12,7 @@
12
  function auxin_get_gmap_master_array( $master_array ) {
13
 
14
  $master_array['aux_gmaps'] = array(
15
- 'name' => __('[Phlox] Map ', 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_gmaps_callback',
17
  'base' => 'aux_gmaps',
18
  'description' => __('Google map block', 'auxin-elements' ),
12
  function auxin_get_gmap_master_array( $master_array ) {
13
 
14
  $master_array['aux_gmaps'] = array(
15
+ 'name' => __('Map ', 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_gmaps_callback',
17
  'base' => 'aux_gmaps',
18
  'description' => __('Google map block', 'auxin-elements' ),
includes/elements/highlight.php CHANGED
@@ -12,7 +12,7 @@
12
  function auxin_get_highlight_master_array( $master_array ) {
13
 
14
  $master_array['aux_highlight'] = array(
15
- 'name' => __("[Phlox] Highlight", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_highlight_callback',
17
  'base' => 'aux_highlight',
18
  'description' => __('Highlighted Text', 'auxin-elements' ),
12
  function auxin_get_highlight_master_array( $master_array ) {
13
 
14
  $master_array['aux_highlight'] = array(
15
+ 'name' => __("Highlight", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_highlight_callback',
17
  'base' => 'aux_highlight',
18
  'description' => __('Highlighted Text', 'auxin-elements' ),
includes/elements/image.php CHANGED
@@ -12,7 +12,7 @@
12
  function auxin_get_image_master_array( $master_array ) {
13
 
14
  $master_array['aux_image'] = array(
15
- 'name' => __("[Phlox] Image", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_image_callback',
17
  'base' => 'aux_image',
18
  'description' => __('Image with lightbox option', 'auxin-elements' ),
12
  function auxin_get_image_master_array( $master_array ) {
13
 
14
  $master_array['aux_image'] = array(
15
+ 'name' => __("Image", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_image_callback',
17
  'base' => 'aux_image',
18
  'description' => __('Image with lightbox option', 'auxin-elements' ),
includes/elements/instagram-feed.php CHANGED
@@ -12,7 +12,7 @@
12
  function auxin_get_instagram_master_array( $master_array ) {
13
 
14
  $master_array['aux_instagram_feed'] = array( // shortcode info here
15
- 'name' => __("[Phlox] instagram feed", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_instagram_feed_callback',
17
  'base' => 'aux_instagram_feed',
18
  'description' => __('It adds an instagram feed element.', 'auxin-elements' ),
12
  function auxin_get_instagram_master_array( $master_array ) {
13
 
14
  $master_array['aux_instagram_feed'] = array( // shortcode info here
15
+ 'name' => __("instagram feed", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_instagram_feed_callback',
17
  'base' => 'aux_instagram_feed',
18
  'description' => __('It adds an instagram feed element.', 'auxin-elements' ),
includes/elements/latest-posts-slider.php CHANGED
@@ -12,7 +12,7 @@
12
  function auxin_get_post_slider_master_array( $master_array ) {
13
 
14
  $master_array['aux_latest_posts_slider'] = array(
15
- 'name' => __('[Phlox] Latest Posts Slider ', 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_latest_posts_slider_callback',
17
  'base' => 'aux_latest_posts_slider',
18
  'description' => __('Slider for latest posts.', 'auxin-elements' ),
@@ -400,7 +400,7 @@ function auxin_latest_posts_slider_callback( $atts, $shortcode_content = null ){
400
  // Defining default attributes
401
  $default_atts = array(
402
  'title' => '',
403
- 'limit_num' => '10',
404
  'order_by' => 'date',
405
  'order_dir' => 'DESC',
406
  'post_type' => 'post',
@@ -441,7 +441,7 @@ function auxin_latest_posts_slider_callback( $atts, $shortcode_content = null ){
441
  'post__in' => array_filter( explode( ',', $include ) ),
442
  'post_status' => 'publish',
443
  'image_size' => 'full',
444
- 'posts_per_page' => ( $exclude_without_image ? -1 : $limit_num ),
445
  'ignore_sticky_posts' => 1
446
  );
447
 
@@ -470,7 +470,7 @@ function auxin_latest_posts_slider_callback( $atts, $shortcode_content = null ){
470
  if( $query_res->have_posts() ): while ( $query_res->have_posts() ) : $query_res->the_post();
471
 
472
  // break the loop if it is reached to the limit
473
- if ( $exclude_without_image && $post_counter == $limit_num ) {
474
  break;
475
  } else {
476
  $post_counter ++;
12
  function auxin_get_post_slider_master_array( $master_array ) {
13
 
14
  $master_array['aux_latest_posts_slider'] = array(
15
+ 'name' => __('Latest Posts Slider ', 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_latest_posts_slider_callback',
17
  'base' => 'aux_latest_posts_slider',
18
  'description' => __('Slider for latest posts.', 'auxin-elements' ),
400
  // Defining default attributes
401
  $default_atts = array(
402
  'title' => '',
403
+ 'slides_num' => '10',
404
  'order_by' => 'date',
405
  'order_dir' => 'DESC',
406
  'post_type' => 'post',
441
  'post__in' => array_filter( explode( ',', $include ) ),
442
  'post_status' => 'publish',
443
  'image_size' => 'full',
444
+ 'posts_per_page' => ( $exclude_without_image ? -1 : $slides_num ),
445
  'ignore_sticky_posts' => 1
446
  );
447
 
470
  if( $query_res->have_posts() ): while ( $query_res->have_posts() ) : $query_res->the_post();
471
 
472
  // break the loop if it is reached to the limit
473
+ if ( $exclude_without_image && $post_counter == $slides_num ) {
474
  break;
475
  } else {
476
  $post_counter ++;
includes/elements/popular-posts-widget.php CHANGED
@@ -20,7 +20,7 @@ function auxin_get_popular_post_widget_master_array( $master_array ) {
20
 
21
 
22
  $master_array['aux_popular_posts_widget'] = array(
23
- 'name' => __('[Phlox] Popular Posts Widget', 'auxin-elements' ),
24
  'auxin_output_callback' => 'auxin_widget_popular_post_widget_callback',
25
  'base' => 'aux_popular_posts_widget',
26
  'description' => __('Shows popular and most commented posts with thumbnail.', 'auxin-elements' ),
20
 
21
 
22
  $master_array['aux_popular_posts_widget'] = array(
23
+ 'name' => __('Popular Posts Widget', 'auxin-elements' ),
24
  'auxin_output_callback' => 'auxin_widget_popular_post_widget_callback',
25
  'base' => 'aux_popular_posts_widget',
26
  'description' => __('Shows popular and most commented posts with thumbnail.', 'auxin-elements' ),
includes/elements/quote.php CHANGED
@@ -12,7 +12,7 @@
12
  function auxin_get_quote_master_array( $master_array ) {
13
 
14
  $master_array['aux_quote'] = array(
15
- 'name' => __("[Phlox] Quote", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_quote_callback',
17
  'base' => 'aux_quote',
18
  'description' => __('Blockquote and introduction paragraph', 'auxin-elements' ),
12
  function auxin_get_quote_master_array( $master_array ) {
13
 
14
  $master_array['aux_quote'] = array(
15
+ 'name' => __("Quote", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_quote_callback',
17
  'base' => 'aux_quote',
18
  'description' => __('Blockquote and introduction paragraph', 'auxin-elements' ),
includes/elements/recent-posts-grid-carousel.php CHANGED
@@ -26,7 +26,7 @@ function auxin_get_recent_posts_master_array( $master_array ) {
26
 
27
 
28
  $master_array['aux_recent_posts'] = array(
29
- 'name' => __('[Phlox] Grid & Carousel Recent Posts', 'auxin-elements' ),
30
  'auxin_output_callback' => 'auxin_widget_recent_posts_callback',
31
  'base' => 'aux_recent_posts',
32
  'description' => __('It adds recent posts in grid or carousel mode.', 'auxin-elements' ),
@@ -347,6 +347,37 @@ function auxin_get_recent_posts_master_array( $master_array ) {
347
  'group' => '',
348
  'edit_field_class' => ''
349
  ),
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
350
  array(
351
  'heading' => __('Excerpt length','auxin-elements' ),
352
  'description' => __('Specify summary content in character.','auxin-elements' ),
@@ -699,8 +730,8 @@ function auxin_widget_recent_posts_callback( $atts, $shortcode_content = null ){
699
  'reset_query' => true,
700
  'wp_query_args' => array(), // additional wp_query args
701
  'custom_wp_query' => '',
702
- 'loadmore_type' => 'scroll', // 'next' (more button), 'scroll', 'next-prev'
703
- 'loadmore_per_page' => 12,
704
  'base' => 'aux_recent_posts',
705
  'base_class' => 'aux-widget-recent-posts'
706
  );
@@ -794,6 +825,10 @@ function auxin_widget_recent_posts_callback( $atts, $shortcode_content = null ){
794
 
795
  $columns_custom_styles = '';
796
 
 
 
 
 
797
  if ( in_array( $preview_mode, array( 'grid', 'grid-table' ) ) ) {
798
  // generate columns class
799
  $column_class = 'aux-match-height aux-row aux-de-col' . $desktop_cnum;
@@ -844,7 +879,7 @@ function auxin_widget_recent_posts_callback( $atts, $shortcode_content = null ){
844
 
845
  if( $have_posts ){
846
 
847
- echo ! $skip_wrappers ? sprintf( '<div class="%s" %s>', $column_class, $carousel_attrs ) : '';
848
 
849
  while ( $wp_query->have_posts() ) {
850
 
@@ -920,13 +955,16 @@ function auxin_widget_recent_posts_callback( $atts, $shortcode_content = null ){
920
  do_action( $base_class . '-template-part', $result, $post_vars, $item_class );
921
 
922
  } else {
923
- printf( '<div class="%s post-%s">', $item_class, $post->ID );
924
  include auxin_get_template_file( $template_part_file, '', $extra_template_path );
925
- echo '</div>';
926
  }
927
 
928
  }
929
 
 
 
 
930
  if ( 'carousel' == $preview_mode && 'arrows' == $carousel_navigation_control ) {
931
  ?>
932
  <div class="aux-carousel-controls">
@@ -942,12 +980,22 @@ function auxin_widget_recent_posts_callback( $atts, $shortcode_content = null ){
942
  <?php
943
  }
944
 
945
- // print the custom inline style if available
946
- echo $columns_custom_styles ? "<style>$columns_custom_styles</style>" : '';
 
 
 
 
 
 
 
 
 
 
947
 
948
- echo ! $skip_wrappers ? '</div>' : '';
949
  }
950
 
 
951
  if( $reset_query ){
952
  wp_reset_postdata();
953
  }
@@ -963,61 +1011,3 @@ function auxin_widget_recent_posts_callback( $atts, $shortcode_content = null ){
963
 
964
  return ob_get_clean();
965
  }
966
-
967
-
968
-
969
-
970
-
971
- /**
972
- * Retrieves the markup of a recent post grid
973
- *
974
- * AJAX Handler: recent-post-grid
975
- *
976
- * Sample Ajax call:
977
- (function($){
978
- $.ajax({
979
- type : "post",
980
- url : auxin.ajaxurl,
981
- data : {
982
- action : "recent-post-grid",
983
- from : 0,
984
- to : 10,
985
- nonce : ''
986
- },
987
- success: function(response){
988
- if(response.type == "success") {
989
-
990
- } else {
991
- alert("Your vote could not be added")
992
- }
993
- }
994
- });
995
- })(jQuery);
996
- */
997
-
998
-
999
- /*
1000
- $data = array(
1001
- 'blog_style' => 'timeline',
1002
- 'slider_autoscroll' => '0',
1003
- 'blog_post_per_page' => '5',
1004
- 'blog_categories' => 'development',
1005
- 'blog_post_types' => 'post',
1006
- 'blog_pagination' => 'more',
1007
- 'blog_ignore_sticky' => '',
1008
- 'is_ajax' => '0',
1009
- 'paged' => '2',
1010
- 'loading_animation' => 'move-up',
1011
- 'hide_date' => '0',
1012
- 'hide_author' => '0',
1013
- 'hide_comments' => '0',
1014
- 'hide_likes' => '0',
1015
- 'buttom' => array(
1016
- 'text' => 'Load More...',
1017
- 'style' => 'flat',
1018
- 'icon' => 'material',
1019
- 'icon_position' => 'left',
1020
- 'separator' => 'load-more'
1021
- )
1022
- );
1023
- */
26
 
27
 
28
  $master_array['aux_recent_posts'] = array(
29
+ 'name' => __('Grid & Carousel Recent Posts', 'auxin-elements' ),
30
  'auxin_output_callback' => 'auxin_widget_recent_posts_callback',
31
  'base' => 'aux_recent_posts',
32
  'description' => __('It adds recent posts in grid or carousel mode.', 'auxin-elements' ),
347
  'group' => '',
348
  'edit_field_class' => ''
349
  ),
350
+ array(
351
+ 'heading' => __('Load More Type','auxin-elements' ),
352
+ 'description' => '',
353
+ 'param_name' => 'loadmore_type',
354
+ 'type' => 'aux_visual_select',
355
+ 'value' => 'scroll',
356
+ 'class' => 'loadmore_type',
357
+ 'admin_label' => false,
358
+ 'dependency' => '',
359
+ 'weight' => '',
360
+ 'group' => '' ,
361
+ 'edit_field_class' => '',
362
+ 'choices' => array(
363
+ '' => array(
364
+ 'label' => __('None', 'auxin-elements' ),
365
+ 'image' => AUXIN_URL . 'images/visual-select/none.svg'
366
+ ),
367
+ 'scroll' => array(
368
+ 'label' => __('Infinite Scroll', 'auxin-elements' ),
369
+ 'image' => AUXIN_URL . 'images/visual-select/button-normal.svg'
370
+ ),
371
+ 'next' => array(
372
+ 'label' => __('Next Button', 'auxin-elements' ),
373
+ 'image' => AUXIN_URL . 'images/visual-select/button-curved.svg'
374
+ ),
375
+ 'next-prev' => array(
376
+ 'label' => __('Next Prev', 'auxin-elements' ),
377
+ 'image' => AUXIN_URL . 'images/visual-select/button-rounded.svg'
378
+ )
379
+ )
380
+ ),
381
  array(
382
  'heading' => __('Excerpt length','auxin-elements' ),
383
  'description' => __('Specify summary content in character.','auxin-elements' ),
730
  'reset_query' => true,
731
  'wp_query_args' => array(), // additional wp_query args
732
  'custom_wp_query' => '',
733
+ 'loadmore_type' => '', // 'next' (more button), 'scroll', 'next-prev'
734
+ 'loadmore_per_page' => '',
735
  'base' => 'aux_recent_posts',
736
  'base_class' => 'aux-widget-recent-posts'
737
  );
825
 
826
  $columns_custom_styles = '';
827
 
828
+ if( ! empty( $loadmore_type ) ) {
829
+ $item_class .= ' aux-ajax-item';
830
+ }
831
+
832
  if ( in_array( $preview_mode, array( 'grid', 'grid-table' ) ) ) {
833
  // generate columns class
834
  $column_class = 'aux-match-height aux-row aux-de-col' . $desktop_cnum;
879
 
880
  if( $have_posts ){
881
 
882
+ echo ! $skip_wrappers ? sprintf( '<div data-element-id="%s" class="%s" %s>', esc_attr( $universal_id ), esc_attr( $column_class ), esc_html( $carousel_attrs ) ) : '';
883
 
884
  while ( $wp_query->have_posts() ) {
885
 
955
  do_action( $base_class . '-template-part', $result, $post_vars, $item_class );
956
 
957
  } else {
958
+ printf( '<div class="%s post-%s">', esc_attr( $item_class ), esc_attr( $post->ID ) );
959
  include auxin_get_template_file( $template_part_file, '', $extra_template_path );
960
+ echo '</div>';
961
  }
962
 
963
  }
964
 
965
+ // print the custom inline style if available
966
+ echo $columns_custom_styles ? "<style>$columns_custom_styles</style>" : '';
967
+
968
  if ( 'carousel' == $preview_mode && 'arrows' == $carousel_navigation_control ) {
969
  ?>
970
  <div class="aux-carousel-controls">
980
  <?php
981
  }
982
 
983
+ if( ! $skip_wrappers ) {
984
+ // End tag for aux-ajax-view wrapper
985
+ echo '</div>';
986
+ // Execute load more functionality
987
+ if( 'carousel' != $preview_mode ) {
988
+ echo auxin_get_load_more_controller( $loadmore_type );
989
+ }
990
+
991
+ } else {
992
+ // Get post counter in the query
993
+ echo '<span class="aux-post-count hidden">'.$wp_query->post_count.'</span>';
994
+ }
995
 
 
996
  }
997
 
998
+
999
  if( $reset_query ){
1000
  wp_reset_postdata();
1001
  }
1011
 
1012
  return ob_get_clean();
1013
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/elements/recent-posts-land-style.php CHANGED
@@ -26,7 +26,7 @@ function auxin_get_recent_posts_land_master_array( $master_array ) {
26
 
27
 
28
  $master_array['aux_recent_posts_land_style'] = array(
29
- 'name' => __('[Phlox] Land Style Recent Posts', 'auxin-elements' ),
30
  'auxin_output_callback' => 'auxin_widget_recent_posts_land_style_callback',
31
  'base' => 'aux_recent_posts_land_style',
32
  'description' => __('It adds recent posts in land style.', 'auxin-elements' ),
@@ -310,6 +310,37 @@ function auxin_get_recent_posts_land_master_array( $master_array ) {
310
  'group' => '',
311
  'edit_field_class' => ''
312
  ),
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
313
  array(
314
  'heading' => __('Excerpt length','auxin-elements' ),
315
  'description' => __('Specify summary content in character.','auxin-elements' ),
@@ -411,11 +442,21 @@ function auxin_widget_recent_posts_land_style_callback( $atts, $shortcode_conten
411
  'author_or_readmore' => 'readmore',
412
  'image_aspect_ratio' => 0.75,
413
  'tag' => '',
 
414
  'extra_classes' => '',
 
415
  'custom_el_id' => '',
 
 
 
 
 
416
  'reset_query' => true,
417
  'use_wp_query' => false, // true to use the global wp_query, false to use internal custom query
418
  'wp_query_args' => array(), // additional wp_query args
 
 
 
419
  'base_class' => 'aux-widget-recent-posts-land'
420
  );
421
 
@@ -497,17 +538,22 @@ function auxin_widget_recent_posts_land_style_callback( $atts, $shortcode_conten
497
 
498
  $show_comments = true; // shows comments icon
499
  $post_counter = 0;
500
- $wrapper_class = 'aux-blog-land-style';
501
  $item_class = 'aux-block';
502
  $post_classes = 'aux-column-post-entry land-post-style';
503
 
 
 
 
 
504
  $column_media_width = auxin_get_content_column_width( 2, 15 );
505
 
506
  // whether any result was found or not
507
  $have_posts = $wp_query->have_posts();
508
 
509
- if( $wp_query->have_posts() ){
510
- echo sprintf( '<div class="%s">', $wrapper_class );
 
511
 
512
  while ( $wp_query->have_posts() ) {
513
 
@@ -530,10 +576,21 @@ function auxin_widget_recent_posts_land_style_callback( $atts, $shortcode_conten
530
  extract( $post_vars );
531
 
532
  $the_format = get_post_format( $post );
533
- include( locate_template( 'templates/theme-parts/entry/post-column.php' ) );
 
 
 
 
 
 
 
 
 
 
 
 
534
  }
535
 
536
- echo '</div>';
537
  }
538
 
539
  if( $reset_query ){
26
 
27
 
28
  $master_array['aux_recent_posts_land_style'] = array(
29
+ 'name' => __('Land Style Recent Posts', 'auxin-elements' ),
30
  'auxin_output_callback' => 'auxin_widget_recent_posts_land_style_callback',
31
  'base' => 'aux_recent_posts_land_style',
32
  'description' => __('It adds recent posts in land style.', 'auxin-elements' ),
310
  'group' => '',
311
  'edit_field_class' => ''
312
  ),
313
+ array(
314
+ 'heading' => __('Load More Type','auxin-elements' ),
315
+ 'description' => '',
316
+ 'param_name' => 'loadmore_type',
317
+ 'type' => 'aux_visual_select',
318
+ 'value' => 'scroll',
319
+ 'class' => 'loadmore_type',
320
+ 'admin_label' => false,
321
+ 'dependency' => '',
322
+ 'weight' => '',
323
+ 'group' => '' ,
324
+ 'edit_field_class' => '',
325
+ 'choices' => array(
326
+ '' => array(
327
+ 'label' => __('None', 'auxin-elements' ),
328
+ 'image' => AUXIN_URL . 'images/visual-select/none.svg'
329
+ ),
330
+ 'scroll' => array(
331
+ 'label' => __('Infinite Scroll', 'auxin-elements' ),
332
+ 'image' => AUXIN_URL . 'images/visual-select/button-normal.svg'
333
+ ),
334
+ 'next' => array(
335
+ 'label' => __('Next Button', 'auxin-elements' ),
336
+ 'image' => AUXIN_URL . 'images/visual-select/button-curved.svg'
337
+ ),
338
+ 'next-prev' => array(
339
+ 'label' => __('Next Prev', 'auxin-elements' ),
340
+ 'image' => AUXIN_URL . 'images/visual-select/button-rounded.svg'
341
+ )
342
+ )
343
+ ),
344
  array(
345
  'heading' => __('Excerpt length','auxin-elements' ),
346
  'description' => __('Specify summary content in character.','auxin-elements' ),
442
  'author_or_readmore' => 'readmore',
443
  'image_aspect_ratio' => 0.75,
444
  'tag' => '',
445
+
446
  'extra_classes' => '',
447
+ 'extra_column_classes' => '',
448
  'custom_el_id' => '',
449
+
450
+ 'template_part_file' => 'theme-parts/entry/post-column',
451
+ 'extra_template_path' => '',
452
+
453
+ 'universal_id' => '',
454
  'reset_query' => true,
455
  'use_wp_query' => false, // true to use the global wp_query, false to use internal custom query
456
  'wp_query_args' => array(), // additional wp_query args
457
+ 'loadmore_type' => '', // 'next' (more button), 'scroll', 'next-prev'
458
+ 'loadmore_per_page' => '',
459
+ 'base' => 'aux_recent_posts_land_style',
460
  'base_class' => 'aux-widget-recent-posts-land'
461
  );
462
 
538
 
539
  $show_comments = true; // shows comments icon
540
  $post_counter = 0;
541
+ $column_class = 'aux-blog-land-style aux-ajax-view ' . $extra_column_classes;
542
  $item_class = 'aux-block';
543
  $post_classes = 'aux-column-post-entry land-post-style';
544
 
545
+ if( ! empty( $loadmore_type ) ) {
546
+ $item_class .= ' aux-ajax-item';
547
+ }
548
+
549
  $column_media_width = auxin_get_content_column_width( 2, 15 );
550
 
551
  // whether any result was found or not
552
  $have_posts = $wp_query->have_posts();
553
 
554
+ if( $have_posts ){
555
+
556
+ echo ! $skip_wrappers ? sprintf( '<div data-element-id="%s" class="%s">', esc_attr( $universal_id ), esc_attr( $column_class ) ) : '';
557
 
558
  while ( $wp_query->have_posts() ) {
559
 
576
  extract( $post_vars );
577
 
578
  $the_format = get_post_format( $post );
579
+
580
+ printf( '<div class="%s post-%s">', esc_attr( $item_class ), esc_attr( $post->ID ) );
581
+ include auxin_get_template_file( $template_part_file, '', $extra_template_path );
582
+ echo '</div>';
583
+ }
584
+
585
+ if( ! $skip_wrappers ) {
586
+ // End tag for aux-ajax-view wrapper & Execute load more functionality
587
+ echo '</div>' . auxin_get_load_more_controller( $loadmore_type );
588
+
589
+ } else {
590
+ // Get post counter in the query
591
+ echo '<span class="aux-post-count hidden">'.$wp_query->post_count.'</span>';
592
  }
593
 
 
594
  }
595
 
596
  if( $reset_query ){
includes/elements/recent-posts-masonry.php CHANGED
@@ -26,7 +26,7 @@ function auxin_get_recent_posts_masonry_master_array( $master_array ) {
26
 
27
 
28
  $master_array['aux_recent_posts_masonry'] = array(
29
- 'name' => __('[Phlox] Masonry Recent Posts', 'auxin-elements' ),
30
  'auxin_output_callback' => 'auxin_widget_recent_posts_masonry_callback',
31
  'base' => 'aux_recent_posts_masonry',
32
  'description' => __('It adds recent posts in masonry style.', 'auxin-elements' ),
@@ -290,6 +290,37 @@ function auxin_get_recent_posts_masonry_master_array( $master_array ) {
290
  'group' => '',
291
  'edit_field_class' => ''
292
  ),
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
293
  array(
294
  'heading' => __('Excerpt length','auxin-elements' ),
295
  'description' => __('Specify summary content in character.','auxin-elements' ),
@@ -444,11 +475,21 @@ function auxin_widget_recent_posts_masonry_callback( $atts, $shortcode_content =
444
  'tablet_cnum' => 'inherit',
445
  'phone_cnum' => '1',
446
  'tag' => '',
 
447
  'extra_classes' => '',
 
448
  'custom_el_id' => '',
 
 
 
 
 
449
  'reset_query' => true,
450
  'use_wp_query' => false, // true to use the global wp_query, false to use internal custom query
451
  'wp_query_args' => array(), // additional wp_query args
 
 
 
452
  'base_class' => 'aux-widget-recent-posts-masonry aux-column-post-entry'
453
  );
454
 
@@ -535,19 +576,25 @@ function auxin_widget_recent_posts_masonry_callback( $atts, $shortcode_content =
535
  $container_class = 'aux-masonry-layout ';
536
  $post_info_position = 'after-title';
537
 
 
 
 
 
538
  // generate columns class
539
- $column_class = $container_class . ' aux-row aux-de-col' . $desktop_cnum;
540
- $tablet_cnum = ('inherit' == $tablet_cnum ) ? $desktop_cnum : $tablet_cnum ;
541
- $column_class .= ' aux-tb-col'.$tablet_cnum . ' aux-mb-col'.$phone_cnum;
542
- $column_class .= 'entry-boxed' == $content_layout ? ' aux-entry-boxed' : '';
543
 
 
544
 
545
  $column_media_width = auxin_get_content_column_width( $desktop_cnum, 15 );
546
 
547
  $have_posts = $wp_query->have_posts();
548
 
549
  if( $have_posts ){
550
- echo sprintf( '<div class="%s">', $column_class );
 
551
 
552
  while ( $wp_query->have_posts() ) {
553
 
@@ -581,15 +628,23 @@ function auxin_widget_recent_posts_masonry_callback( $atts, $shortcode_content =
581
 
582
  $the_format = get_post_format( $post );
583
 
584
- printf( '<div class="%s">', $item_class );
585
- include( locate_template( 'templates/theme-parts/entry/post-column.php' ) );
586
- echo '</div>';
 
 
 
587
  }
588
 
589
- // use it as data attribute on load more button
590
- $ajax_nonce = wp_create_nonce( 'post-recent-grid-nonce' );
 
 
 
 
 
 
591
 
592
- echo '</div>';
593
  }
594
 
595
  if( $reset_query ){
@@ -606,53 +661,4 @@ function auxin_widget_recent_posts_masonry_callback( $atts, $shortcode_content =
606
  echo $result['widget_footer'];
607
 
608
  return ob_get_clean();
609
- }
610
-
611
-
612
-
613
-
614
- /**
615
- * Retrieves the markup of a recent post grid
616
- *
617
- * AJAX Handler: recent-post-grid
618
- *
619
- * Sample Ajax call:
620
- (function($){
621
- $.ajax({
622
- type : "post",
623
- url : auxin.ajaxurl,
624
- data : {
625
- action : "recent-post-grid",
626
- from : 0,
627
- to : 10,
628
- nonce : ''
629
- },
630
- success: function(response){
631
- if(response.type == "success") {
632
-
633
- } else {
634
- alert("Your vote could not be added")
635
- }
636
- }
637
- });
638
- })(jQuery);
639
- */
640
- // function auxin_widget_recent_posts_grid_ajax_callback(){
641
-
642
- // if( empty( $_POST['action'] ) ){
643
- // wp_send_json_error( __( 'Action handler not found.', 'auxin-elements' ) );
644
- // } elseif( ! wp_verify_nonce( $_POST['nonce'], 'post-recent-grid-nonce' ) ){
645
- // wp_send_json_error( __( 'Authorization failed.', 'auxin-elements' ) );
646
- // }
647
-
648
- // $from = $_POST['from'];
649
- // $to = $_POST['to'];
650
-
651
- // //wp_send_json_success( array() );
652
-
653
- // //wp_send_json_error( __( 'An error occurred.', 'auxin-elements' ) );
654
- // }
655
-
656
- add_action( 'wp_ajax_recent-post-grid', 'auxin_widget_recent_posts_grid_ajax_callback' );
657
-
658
-
26
 
27
 
28
  $master_array['aux_recent_posts_masonry'] = array(
29
+ 'name' => __('Masonry Recent Posts', 'auxin-elements' ),
30
  'auxin_output_callback' => 'auxin_widget_recent_posts_masonry_callback',
31
  'base' => 'aux_recent_posts_masonry',
32
  'description' => __('It adds recent posts in masonry style.', 'auxin-elements' ),
290
  'group' => '',
291
  'edit_field_class' => ''
292
  ),
293
+ array(
294
+ 'heading' => __('Load More Type','auxin-elements' ),
295
+ 'description' => '',
296
+ 'param_name' => 'loadmore_type',
297
+ 'type' => 'aux_visual_select',
298
+ 'value' => 'scroll',
299
+ 'class' => 'loadmore_type',
300
+ 'admin_label' => false,
301
+ 'dependency' => '',
302
+ 'weight' => '',
303
+ 'group' => '' ,
304
+ 'edit_field_class' => '',
305
+ 'choices' => array(
306
+ '' => array(
307
+ 'label' => __('None', 'auxin-elements' ),
308
+ 'image' => AUXIN_URL . 'images/visual-select/none.svg'
309
+ ),
310
+ 'scroll' => array(
311
+ 'label' => __('Infinite Scroll', 'auxin-elements' ),
312
+ 'image' => AUXIN_URL . 'images/visual-select/button-normal.svg'
313
+ ),
314
+ 'next' => array(
315
+ 'label' => __('Next Button', 'auxin-elements' ),
316
+ 'image' => AUXIN_URL . 'images/visual-select/button-curved.svg'
317
+ ),
318
+ 'next-prev' => array(
319
+ 'label' => __('Next Prev', 'auxin-elements' ),
320
+ 'image' => AUXIN_URL . 'images/visual-select/button-rounded.svg'
321
+ )
322
+ )
323
+ ),
324
  array(
325
  'heading' => __('Excerpt length','auxin-elements' ),
326
  'description' => __('Specify summary content in character.','auxin-elements' ),
475
  'tablet_cnum' => 'inherit',
476
  'phone_cnum' => '1',
477
  'tag' => '',
478
+
479
  'extra_classes' => '',
480
+ 'extra_column_classes' => '',
481
  'custom_el_id' => '',
482
+
483
+ 'template_part_file' => 'theme-parts/entry/post-column',
484
+ 'extra_template_path' => '',
485
+
486
+ 'universal_id' => '',
487
  'reset_query' => true,
488
  'use_wp_query' => false, // true to use the global wp_query, false to use internal custom query
489
  'wp_query_args' => array(), // additional wp_query args
490
+ 'loadmore_type' => '', // 'next' (more button), 'scroll', 'next-prev'
491
+ 'loadmore_per_page' => '',
492
+ 'base' => 'aux_recent_posts_masonry',
493
  'base_class' => 'aux-widget-recent-posts-masonry aux-column-post-entry'
494
  );
495
 
576
  $container_class = 'aux-masonry-layout ';
577
  $post_info_position = 'after-title';
578
 
579
+ if( ! empty( $loadmore_type ) ) {
580
+ $item_class .= ' aux-ajax-item';
581
+ }
582
+
583
  // generate columns class
584
+ $column_class = $container_class . ' aux-row aux-de-col' . $desktop_cnum;
585
+ $tablet_cnum = ('inherit' == $tablet_cnum ) ? $desktop_cnum : $tablet_cnum ;
586
+ $column_class .= ' aux-tb-col'.$tablet_cnum . ' aux-mb-col'.$phone_cnum;
587
+ $column_class .= 'entry-boxed' == $content_layout ? ' aux-entry-boxed' : '';
588
 
589
+ $column_class .= ' aux-ajax-view ' . $extra_column_classes;
590
 
591
  $column_media_width = auxin_get_content_column_width( $desktop_cnum, 15 );
592
 
593
  $have_posts = $wp_query->have_posts();
594
 
595
  if( $have_posts ){
596
+
597
+ echo ! $skip_wrappers ? sprintf( '<div data-element-id="%s" class="%s">', esc_attr( $universal_id ), esc_attr( $column_class ) ) : '';
598
 
599
  while ( $wp_query->have_posts() ) {
600
 
628
 
629
  $the_format = get_post_format( $post );
630
 
631
+ // add specific class to current classes for each column
632
+ $post_classes = $has_attach && $show_media ? 'post column-entry' : 'post column-entry no-media';
633
+
634
+ printf( '<div class="%s post-%s">', esc_attr( $item_class ), esc_attr( $post->ID ) );
635
+ include auxin_get_template_file( $template_part_file, '', $extra_template_path );
636
+ echo '</div>';
637
  }
638
 
639
+ if( ! $skip_wrappers ) {
640
+ // End tag for aux-ajax-view wrapper & Execute load more functionality
641
+ echo '</div>' . auxin_get_load_more_controller( $loadmore_type );
642
+
643
+ } else {
644
+ // Get post counter in the query
645
+ echo '<span class="aux-post-count hidden">'.$wp_query->post_count.'</span>';
646
+ }
647
 
 
648
  }
649
 
650
  if( $reset_query ){
661
  echo $result['widget_footer'];
662
 
663
  return ob_get_clean();
664
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/elements/recent-posts-tiles.php CHANGED
@@ -26,7 +26,7 @@ function auxin_get_recent_posts_tiles_master_array( $master_array ) {
26
 
27
 
28
  $master_array['aux_recent_posts_tiles'] = array(
29
- 'name' => __('[Phlox] Tiles Recent Posts', 'auxin-elements' ),
30
  'auxin_output_callback' => 'auxin_widget_recent_posts_tiles_callback',
31
  'base' => 'aux_recent_posts_tiles',
32
  'description' => __('It adds recent posts in tiles style.', 'auxin-elements' ),
@@ -137,6 +137,37 @@ function auxin_get_recent_posts_tiles_master_array( $master_array ) {
137
  'group' => 'Query',
138
  'edit_field_class' => ''
139
  ),
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
140
  array(
141
  'heading' => __('Order by', 'auxin-elements'),
142
  'description' => '',
@@ -371,23 +402,34 @@ function auxin_widget_recent_posts_tiles_callback( $atts, $shortcode_content = n
371
  'only_posts__in' => '', // display only these post IDs. array or string comma separated
372
  'include' => '', // include these post IDs in result too. array or string comma separated
373
  'exclude' => '', // exclude these post IDs from result. array or string comma separated
 
374
  'offset' => '',
375
  'paged' => '',
376
  'order_by' => 'date',
377
  'order' => 'DESC',
378
  'excerpt_len' => '160',
379
- 'exclude_without_media' => '1',
380
- 'exclude_custom_post_formats' => '1',
381
- 'exclude_quote_link' => '1',
382
  'exclude_post_formats_in' => array(), // the list od post formats to exclude
383
  'tile_style' => '',
384
- 'display_title' => '1',
385
- 'show_info' => '1',
 
386
  'extra_classes' => '',
 
387
  'custom_el_id' => '',
 
 
 
 
 
388
  'reset_query' => true,
389
  'use_wp_query' => false, // true to use the global wp_query, false to use internal custom query
390
  'wp_query_args' => array(), // additional wp_query args
 
 
 
391
  'base_class' => 'aux-widget-recent-posts-tiles'
392
  );
393
 
@@ -426,8 +468,6 @@ function auxin_widget_recent_posts_tiles_callback( $atts, $shortcode_content = n
426
  'offset' => $offset,
427
  'paged' => $paged,
428
  'cat' => $cat,
429
- 'post__not_in' => array_filter( explode( ',', $exclude ) ),
430
- 'post__in' => array_filter( explode( ',', $include ) ),
431
  'post_status' => 'publish',
432
  'posts_per_page' => $num,
433
  'ignore_sticky_posts' => 1,
@@ -461,46 +501,58 @@ function auxin_widget_recent_posts_tiles_callback( $atts, $shortcode_content = n
461
  $post_counter = 0;
462
  $item_class = 'aux-post-tile aux-image-box';
463
 
464
- $container_class = 'aux-tiles-layout ' . $tile_style;
 
 
 
 
465
  $column_media_width = auxin_get_content_column_width( 4, 0 );
466
 
467
  $have_posts = $wp_query->have_posts();
468
 
469
  if( $have_posts ){
470
 
471
- echo sprintf( '<div class="%s">', $container_class );
472
 
473
  while ( $wp_query->have_posts() ) {
474
 
475
  $wp_query->the_post();
476
  $post = $wp_query->post;
477
 
478
- $the_format = get_post_format( $post );
479
  $item_pattern_info = auxin_get_tile_pattern( 'default', $post_counter, $column_media_width );
480
  $post_counter++;
481
 
482
  $post_vars = auxin_get_post_format_media(
483
  $post,
484
  array(
485
- 'request_from' => 'archive',
486
- 'media_width' => $phone_break_point,
487
- 'media_size' => 'large',
488
- 'upscale_image' => true,
489
- 'ignore_formats' => array( '*' ),
490
- 'add_image_hw' => false, // whether add width and height attr or not
491
- 'image_sizes' => $item_pattern_info['image_sizes'],
492
- 'srcset_sizes' => $item_pattern_info['srcset_sizes']
493
  )
494
  );
495
 
496
  extract( $post_vars );
497
 
498
- $post_classes = $item_class .' '. $item_pattern_info['classname'];
 
 
499
 
500
- include( locate_template( 'templates/theme-parts/entry/post-tile.php' ) );
501
  }
502
 
503
- echo '</div>';
 
 
 
 
 
 
 
504
  }
505
 
506
  if( $reset_query ){
26
 
27
 
28
  $master_array['aux_recent_posts_tiles'] = array(
29
+ 'name' => __('Tiles Recent Posts', 'auxin-elements' ),
30
  'auxin_output_callback' => 'auxin_widget_recent_posts_tiles_callback',
31
  'base' => 'aux_recent_posts_tiles',
32
  'description' => __('It adds recent posts in tiles style.', 'auxin-elements' ),
137
  'group' => 'Query',
138
  'edit_field_class' => ''
139
  ),
140
+ array(
141
+ 'heading' => __('Load More Type','auxin-elements' ),
142
+ 'description' => '',
143
+ 'param_name' => 'loadmore_type',
144
+ 'type' => 'aux_visual_select',
145
+ 'value' => 'scroll',
146
+ 'class' => 'loadmore_type',
147
+ 'admin_label' => false,
148
+ 'dependency' => '',
149
+ 'weight' => '',
150
+ 'group' => '' ,
151
+ 'edit_field_class' => '',
152
+ 'choices' => array(
153
+ '' => array(
154
+ 'label' => __('None', 'auxin-elements' ),
155
+ 'image' => AUXIN_URL . 'images/visual-select/none.svg'
156
+ ),
157
+ 'scroll' => array(
158
+ 'label' => __('Infinite Scroll', 'auxin-elements' ),
159
+ 'image' => AUXIN_URL . 'images/visual-select/button-normal.svg'
160
+ ),
161
+ 'next' => array(
162
+ 'label' => __('Next Button', 'auxin-elements' ),
163
+ 'image' => AUXIN_URL . 'images/visual-select/button-curved.svg'
164
+ ),
165
+ 'next-prev' => array(
166
+ 'label' => __('Next Prev', 'auxin-elements' ),
167
+ 'image' => AUXIN_URL . 'images/visual-select/button-rounded.svg'
168
+ )
169
+ )
170
+ ),
171
  array(
172
  'heading' => __('Order by', 'auxin-elements'),
173
  'description' => '',
402
  'only_posts__in' => '', // display only these post IDs. array or string comma separated
403
  'include' => '', // include these post IDs in result too. array or string comma separated
404
  'exclude' => '', // exclude these post IDs from result. array or string comma separated
405
+ 'posts_per_page' => -1,
406
  'offset' => '',
407
  'paged' => '',
408
  'order_by' => 'date',
409
  'order' => 'DESC',
410
  'excerpt_len' => '160',
411
+ 'exclude_without_media' => true,
412
+ 'exclude_custom_post_formats' => true,
413
+ 'exclude_quote_link' => true,
414
  'exclude_post_formats_in' => array(), // the list od post formats to exclude
415
  'tile_style' => '',
416
+ 'display_title' => true,
417
+ 'show_info' => true,
418
+
419
  'extra_classes' => '',
420
+ 'extra_column_classes' => '',
421
  'custom_el_id' => '',
422
+
423
+ 'template_part_file' => 'theme-parts/entry/post-tile',
424
+ 'extra_template_path' => '',
425
+
426
+ 'universal_id' => '',
427
  'reset_query' => true,
428
  'use_wp_query' => false, // true to use the global wp_query, false to use internal custom query
429
  'wp_query_args' => array(), // additional wp_query args
430
+ 'loadmore_type' => '', // 'next' (more button), 'scroll', 'next-prev'
431
+ 'loadmore_per_page' => '',
432
+ 'base' => 'aux_recent_posts_tiles',
433
  'base_class' => 'aux-widget-recent-posts-tiles'
434
  );
435
 
468
  'offset' => $offset,
469
  'paged' => $paged,
470
  'cat' => $cat,
 
 
471
  'post_status' => 'publish',
472
  'posts_per_page' => $num,
473
  'ignore_sticky_posts' => 1,
501
  $post_counter = 0;
502
  $item_class = 'aux-post-tile aux-image-box';
503
 
504
+ if( ! empty( $loadmore_type ) ) {
505
+ $item_class .= ' aux-ajax-item';
506
+ }
507
+
508
+ $container_class = 'aux-tiles-layout aux-ajax-view ' . $tile_style;
509
  $column_media_width = auxin_get_content_column_width( 4, 0 );
510
 
511
  $have_posts = $wp_query->have_posts();
512
 
513
  if( $have_posts ){
514
 
515
+ echo ! $skip_wrappers ? sprintf( '<div data-element-id="%s" class="%s">', esc_attr( $universal_id ), esc_attr( $container_class ) ) : '';
516
 
517
  while ( $wp_query->have_posts() ) {
518
 
519
  $wp_query->the_post();
520
  $post = $wp_query->post;
521
 
 
522
  $item_pattern_info = auxin_get_tile_pattern( 'default', $post_counter, $column_media_width );
523
  $post_counter++;
524
 
525
  $post_vars = auxin_get_post_format_media(
526
  $post,
527
  array(
528
+ 'request_from' => 'archive',
529
+ 'media_width' => $phone_break_point,
530
+ 'media_size' => 'large',
531
+ 'upscale_image' => true,
532
+ 'image_from_content' => ! $exclude_without_media,
533
+ 'ignore_formats' => array( '*' ),
534
+ 'image_sizes' => $item_pattern_info['image_sizes'],
535
+ 'srcset_sizes' => $item_pattern_info['srcset_sizes']
536
  )
537
  );
538
 
539
  extract( $post_vars );
540
 
541
+ $post_classes = $item_class .' post '. $item_pattern_info['classname'];
542
+
543
+ $the_format = get_post_format( $post );
544
 
545
+ include auxin_get_template_file( $template_part_file, '', $extra_template_path );
546
  }
547
 
548
+ if( ! $skip_wrappers ) {
549
+ // End tag for aux-ajax-view wrapper & Execute load more functionality
550
+ echo '</div>' . auxin_get_load_more_controller( $loadmore_type );
551
+
552
+ } else {
553
+ // Get post counter in the query
554
+ echo '<span class="aux-post-count hidden">'.$wp_query->post_count.'</span>';
555
+ }
556
  }
557
 
558
  if( $reset_query ){
includes/elements/recent-posts-timeline.php CHANGED
@@ -20,7 +20,7 @@ function auxin_get_recent_posts_timeline_master_array( $master_array ) {
20
 
21
 
22
  $master_array['aux_recent_posts_timeline'] = array(
23
- 'name' => __('[Phlox] Timeline Recent Posts', 'auxin-elements' ),
24
  'auxin_output_callback' => 'auxin_widget_recent_posts_timeline_callback',
25
  'base' => 'aux_recent_posts_timeline',
26
  'description' => __('It adds recent posts in timeline style.', 'auxin-elements' ),
@@ -180,6 +180,37 @@ function auxin_get_recent_posts_timeline_master_array( $master_array ) {
180
  'group' => 'Query',
181
  'edit_field_class' => ''
182
  ),
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
183
  array(
184
  'heading' => __('Order by', 'auxin-elements'),
185
  'description' => '',
@@ -431,11 +462,21 @@ function auxin_widget_recent_posts_timeline_callback( $atts, $shortcode_content
431
  'display_like' => true,
432
  'display_categories' => true,
433
  'tag' => '',
 
434
  'extra_classes' => '',
 
435
  'custom_el_id' => '',
 
 
 
 
 
436
  'reset_query' => true,
437
  'use_wp_query' => false, // true to use the global wp_query, false to use internal custom query
438
  'wp_query_args' => array(), // additional wp_query args
 
 
 
439
  'base_class' => 'aux-widget-recent-posts-timeline aux-column-post-entry'
440
  );
441
 
@@ -515,12 +556,16 @@ function auxin_widget_recent_posts_timeline_callback( $atts, $shortcode_content
515
  $tablet_break_point = 992;
516
 
517
  $show_comments = true; // shows comments icon
518
- $wrapper_class = 'aux-timeline aux-'.$timeline_alignment;
519
  $item_class = 'aux-block';
520
- $post_classes = 'aux-block';
521
  $post_info_position = 'after-title';
522
  $previous_post_month = '';
523
 
 
 
 
 
524
  // calculate the media width
525
  $media_width = 'center' == $timeline_alignment ? $aux_content_width / 2 : $aux_content_width;
526
 
@@ -528,9 +573,9 @@ function auxin_widget_recent_posts_timeline_callback( $atts, $shortcode_content
528
  $have_posts = $wp_query->have_posts();
529
 
530
 
531
- if( $wp_query->have_posts() ){
532
 
533
- echo sprintf( '<div class="%s" data-layout="%s">', $wrapper_class, $timeline_alignment );
534
 
535
  while ( $wp_query->have_posts() ) {
536
 
@@ -543,10 +588,9 @@ function auxin_widget_recent_posts_timeline_callback( $atts, $shortcode_content
543
  'post_type' => 'post',
544
  'request_from' => 'archive',
545
  'media_width' => $phone_break_point,
546
- 'media_size' => 'large',
547
  'upscale_image' => true,
548
  'image_from_content' => ! $exclude_without_media, // whether to try to get image from content or not
549
- 'add_image_hw' => false, // whether add width and height attr or not
550
  'image_sizes' => array(
551
  array( 'min' => '', 'max' => '767px', 'width' => '80vw' ),
552
  array( 'min' => '768px', 'max' => '992px', 'width' => '40vw' ),
@@ -573,11 +617,22 @@ function auxin_widget_recent_posts_timeline_callback( $atts, $shortcode_content
573
  ?><span class="aux-date-label"><?php the_time(); ?></span><?php
574
  }
575
 
576
- include( locate_template( 'templates/theme-parts/entry/post-column.php' ) );
577
- $previous_post_month = $post_month;
 
 
 
578
  }
579
 
580
- echo "</div>";
 
 
 
 
 
 
 
 
581
  }
582
 
583
  if( $reset_query ){
20
 
21
 
22
  $master_array['aux_recent_posts_timeline'] = array(
23
+ 'name' => __('Timeline Recent Posts', 'auxin-elements' ),
24
  'auxin_output_callback' => 'auxin_widget_recent_posts_timeline_callback',
25
  'base' => 'aux_recent_posts_timeline',
26
  'description' => __('It adds recent posts in timeline style.', 'auxin-elements' ),
180
  'group' => 'Query',
181
  'edit_field_class' => ''
182
  ),
183
+ array(
184
+ 'heading' => __('Load More Type','auxin-elements' ),
185
+ 'description' => '',
186
+ 'param_name' => 'loadmore_type',
187
+ 'type' => 'aux_visual_select',
188
+ 'value' => 'scroll',
189
+ 'class' => 'loadmore_type',
190
+ 'admin_label' => false,
191
+ 'dependency' => '',
192
+ 'weight' => '',
193
+ 'group' => '' ,
194
+ 'edit_field_class' => '',
195
+ 'choices' => array(
196
+ '' => array(
197
+ 'label' => __('None', 'auxin-elements' ),
198
+ 'image' => AUXIN_URL . 'images/visual-select/none.svg'
199
+ ),
200
+ 'scroll' => array(
201
+ 'label' => __('Infinite Scroll', 'auxin-elements' ),
202
+ 'image' => AUXIN_URL . 'images/visual-select/button-normal.svg'
203
+ ),
204
+ 'next' => array(
205
+ 'label' => __('Next Button', 'auxin-elements' ),
206
+ 'image' => AUXIN_URL . 'images/visual-select/button-curved.svg'
207
+ ),
208
+ 'next-prev' => array(
209
+ 'label' => __('Next Prev', 'auxin-elements' ),
210
+ 'image' => AUXIN_URL . 'images/visual-select/button-rounded.svg'
211
+ )
212
+ )
213
+ ),
214
  array(
215
  'heading' => __('Order by', 'auxin-elements'),
216
  'description' => '',
462
  'display_like' => true,
463
  'display_categories' => true,
464
  'tag' => '',
465
+
466
  'extra_classes' => '',
467
+ 'extra_column_classes' => '',
468
  'custom_el_id' => '',
469
+
470
+ 'template_part_file' => 'theme-parts/entry/post-column',
471
+ 'extra_template_path' => '',
472
+
473
+ 'universal_id' => '',
474
  'reset_query' => true,
475
  'use_wp_query' => false, // true to use the global wp_query, false to use internal custom query
476
  'wp_query_args' => array(), // additional wp_query args
477
+ 'loadmore_type' => '', // 'next' (more button), 'scroll', 'next-prev'
478
+ 'loadmore_per_page' => '',
479
+ 'base' => 'aux_recent_posts_timeline',
480
  'base_class' => 'aux-widget-recent-posts-timeline aux-column-post-entry'
481
  );
482
 
556
  $tablet_break_point = 992;
557
 
558
  $show_comments = true; // shows comments icon
559
+ $wrapper_class = 'aux-timeline aux-ajax-view aux-'.$timeline_alignment;
560
  $item_class = 'aux-block';
561
+ $post_classes = 'post';
562
  $post_info_position = 'after-title';
563
  $previous_post_month = '';
564
 
565
+ if( ! empty( $loadmore_type ) ) {
566
+ $item_class .= ' aux-ajax-item';
567
+ }
568
+
569
  // calculate the media width
570
  $media_width = 'center' == $timeline_alignment ? $aux_content_width / 2 : $aux_content_width;
571
 
573
  $have_posts = $wp_query->have_posts();
574
 
575
 
576
+ if( $have_posts ){
577
 
578
+ echo ! $skip_wrappers ? sprintf( '<div data-element-id="%s" class="%s" data-layout="%s">', esc_attr( $universal_id ), esc_attr( $wrapper_class ), esc_attr( $timeline_alignment ) ) : '';
579
 
580
  while ( $wp_query->have_posts() ) {
581
 
588
  'post_type' => 'post',
589
  'request_from' => 'archive',
590
  'media_width' => $phone_break_point,
591
+ 'media_size' => 'full',
592
  'upscale_image' => true,
593
  'image_from_content' => ! $exclude_without_media, // whether to try to get image from content or not
 
594
  'image_sizes' => array(
595
  array( 'min' => '', 'max' => '767px', 'width' => '80vw' ),
596
  array( 'min' => '768px', 'max' => '992px', 'width' => '40vw' ),
617
  ?><span class="aux-date-label"><?php the_time(); ?></span><?php
618
  }
619
 
620
+ printf( '<div class="%s post-%s">', esc_attr( $item_class ), esc_attr( $post->ID ) );
621
+ include auxin_get_template_file( $template_part_file, '', $extra_template_path );
622
+ echo '</div>';
623
+
624
+ $previous_post_month = $post_month;
625
  }
626
 
627
+ if( ! $skip_wrappers ) {
628
+ // End tag for aux-ajax-view wrapper & Execute load more functionality
629
+ echo '</div>' . auxin_get_load_more_controller( $loadmore_type );
630
+
631
+ } else {
632
+ // Get post counter in the query
633
+ echo '<span class="aux-post-count hidden">'.$wp_query->post_count.'</span>';
634
+ }
635
+
636
  }
637
 
638
  if( $reset_query ){
includes/elements/recent-posts-widget.php CHANGED
@@ -26,7 +26,7 @@ function auxin_get_recent_post_widget_master_array( $master_array ) {
26
 
27
 
28
  $master_array['aux_recent_post_widget'] = array(
29
- 'name' => __('[Phlox] Recent Posts Widget', 'auxin-elements' ),
30
  'auxin_output_callback' => 'auxin_widget_recent_post_widget_callback',
31
  'base' => 'aux_recent_post_widget',
32
  'description' => __('Shows recent posts with thumbnail.', 'auxin-elements' ),
26
 
27
 
28
  $master_array['aux_recent_post_widget'] = array(
29
+ 'name' => __('Recent Posts Widget', 'auxin-elements' ),
30
  'auxin_output_callback' => 'auxin_widget_recent_post_widget_callback',
31
  'base' => 'aux_recent_post_widget',
32
  'description' => __('Shows recent posts with thumbnail.', 'auxin-elements' ),
includes/elements/search.php CHANGED
@@ -11,7 +11,7 @@
11
  */
12
  function auxin_get_search_master_array( $master_array ) {
13
  $master_array['aux_search'] = array(
14
- 'name' => __("[Phlox] Search", 'auxin-elements' ),
15
  'auxin_output_callback' => 'auxin_widget_search_field_callcack',
16
  'base' => 'aux_search',
17
  'description' => __('Fancy search field', 'auxin-elements'),
11
  */
12
  function auxin_get_search_master_array( $master_array ) {
13
  $master_array['aux_search'] = array(
14
+ 'name' => __("Search", 'auxin-elements' ),
15
  'auxin_output_callback' => 'auxin_widget_search_field_callcack',
16
  'base' => 'aux_search',
17
  'description' => __('Fancy search field', 'auxin-elements'),
includes/elements/socials-list.php CHANGED
@@ -12,7 +12,7 @@
12
  function auxin_get_social_master_array( $master_array ) {
13
 
14
  $master_array['aux_socials_list'] = array(
15
- 'name' => __("[Phlox] Socials", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_socials_list_callback',
17
  'base' => 'aux_socials_list',
18
  'description' => __('It shows the website socials icons which you can configure it by the customizer.', 'auxin-elements'),
12
  function auxin_get_social_master_array( $master_array ) {
13
 
14
  $master_array['aux_socials_list'] = array(
15
+ 'name' => __("Socials", 'auxin-elements' ),
16
  'auxin_output_callback' => 'auxin_widget_socials_list_callback',
17
  'base' => 'aux_socials_list',
18
  'description' => __('It shows the website socials icons which you can configure it by the customizer.', 'auxin-elements'),
includes/elements/staff.php ADDED
@@ -0,0 +1,654 @@