Shortcodes by Angie Makes - Version 1.85

Version Description

Download this release

Release Info

Developer cbaldelomar
Plugin Icon wp plugin Shortcodes by Angie Makes
Version 1.85
Comparing to
See all releases

Code changes from version 1.84 to 1.85

Files changed (4) hide show
  1. README.md +4 -0
  2. includes/shortcode-functions.php +14 -11
  3. readme.txt +4 -0
  4. wc-shortcodes.php +2 -2
README.md CHANGED
@@ -66,6 +66,10 @@ Use the shortcode manager in the TinyMCE text editor
66
 
67
  ## Changelog ##
68
 
 
 
 
 
69
  ### Version 1.84
70
 
71
  * Added share buttons shortcode
66
 
67
  ## Changelog ##
68
 
69
+ ### Version 1.85
70
+
71
+ * add support for single column in wc_posts
72
+
73
  ### Version 1.84
74
 
75
  * Added share buttons shortcode
includes/shortcode-functions.php CHANGED
@@ -1184,16 +1184,6 @@ if( ! function_exists( 'wc_shortcodes_posts' ) ) {
1184
  $display['layout'] = "masonry";
1185
  }
1186
 
1187
- $is_masonry = 'masonry' == $display['layout'] ? true : false;
1188
- $is_grid = 'grid' == $display['layout'] ? true : false;
1189
-
1190
- if ( $is_masonry ) {
1191
- wp_enqueue_script('wc-shortcodes-posts');
1192
- }
1193
- else if ( $is_grid ) {
1194
- wp_enqueue_script('wc-shortcodes-posts-grid');
1195
- }
1196
-
1197
  $valid_templates = array( 'box', 'borderless' );
1198
  if ( ! in_array( $display['template'], $valid_templates ) ) {
1199
  $display['template'] = "box";
@@ -1260,8 +1250,11 @@ if( ! function_exists( 'wc_shortcodes_posts' ) ) {
1260
  $valid_headings = array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' );
1261
  $display['heading_type'] = in_array( $display['heading_type'], $valid_headings ) ? $display['heading_type'] : 'h2';
1262
 
1263
- $valid_columns = array( 2, 3, 4, 5, 6, 7, 8, 9 );
1264
  $display['columns'] = in_array( $display['columns'], $valid_columns ) ? $display['columns'] : 2;
 
 
 
1265
 
1266
  ($display['title'] == "yes") ? ($display['title'] = true) : ($display['title'] = false);
1267
  ($display['meta_all'] == "yes") ? ($display['meta_all'] = true) : ($display['meta_all'] = false);
@@ -1274,6 +1267,16 @@ if( ! function_exists( 'wc_shortcodes_posts' ) ) {
1274
  ($display['filtering'] == "yes") ? ($display['filtering'] = true) : ($display['filtering'] = false);
1275
  ($atts['order'] == "ASC") ? ($atts['order'] = "ASC") : ($atts['order'] = "DESC");
1276
 
 
 
 
 
 
 
 
 
 
 
1277
  $nav_filter_hard_links = false;
1278
  if ( $display['paging'] ) {
1279
  $nav_filter_hard_links = true;
1184
  $display['layout'] = "masonry";
1185
  }
1186
 
 
 
 
 
 
 
 
 
 
 
1187
  $valid_templates = array( 'box', 'borderless' );
1188
  if ( ! in_array( $display['template'], $valid_templates ) ) {
1189
  $display['template'] = "box";
1250
  $valid_headings = array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' );
1251
  $display['heading_type'] = in_array( $display['heading_type'], $valid_headings ) ? $display['heading_type'] : 'h2';
1252
 
1253
+ $valid_columns = array( 1, 2, 3, 4, 5, 6, 7, 8, 9 );
1254
  $display['columns'] = in_array( $display['columns'], $valid_columns ) ? $display['columns'] : 2;
1255
+ if ( $display['columns'] == 1 ) {
1256
+ $display['layout'] = 'single-column';
1257
+ }
1258
 
1259
  ($display['title'] == "yes") ? ($display['title'] = true) : ($display['title'] = false);
1260
  ($display['meta_all'] == "yes") ? ($display['meta_all'] = true) : ($display['meta_all'] = false);
1267
  ($display['filtering'] == "yes") ? ($display['filtering'] = true) : ($display['filtering'] = false);
1268
  ($atts['order'] == "ASC") ? ($atts['order'] = "ASC") : ($atts['order'] = "DESC");
1269
 
1270
+ $is_masonry = 'masonry' == $display['layout'] ? true : false;
1271
+ $is_grid = 'grid' == $display['layout'] ? true : false;
1272
+
1273
+ if ( $is_masonry ) {
1274
+ wp_enqueue_script('wc-shortcodes-posts');
1275
+ }
1276
+ else if ( $is_grid ) {
1277
+ wp_enqueue_script('wc-shortcodes-posts-grid');
1278
+ }
1279
+
1280
  $nav_filter_hard_links = false;
1281
  if ( $display['paging'] ) {
1282
  $nav_filter_hard_links = true;
readme.txt CHANGED
@@ -88,6 +88,10 @@ Use the shortcode manager in the TinyMCE text editor
88
 
89
  == Changelog ==
90
 
 
 
 
 
91
  = Version 1.84 =
92
 
93
  * Added share buttons shortcode
88
 
89
  == Changelog ==
90
 
91
+ = Version 1.85 =
92
+
93
+ * add support for single column in wc_posts
94
+
95
  = Version 1.84 =
96
 
97
  * Added share buttons shortcode
wc-shortcodes.php CHANGED
@@ -5,11 +5,11 @@ Plugin URI: http://webplantmedia.com/starter-themes/wordpresscanvas/features/sho
5
  Description: A family of shortcodes to enhance site functionality.
6
  Author: Chris Baldelomar
7
  Author URI: http://webplantmedia.com/
8
- Version: 1.84
9
  License: GPLv2 or later
10
  */
11
 
12
- define( 'WC_SHORTCODES_VERSION', '1.84' );
13
  define( 'WC_SHORTCODES_PREFIX', 'wc_shortcodes_' );
14
  define( '_WC_SHORTCODES_PREFIX', '_wc_shortcodes_' );
15
  define( 'WC_SHORTCODES_PLUGIN_URL', plugin_dir_url( __FILE__ ) );
5
  Description: A family of shortcodes to enhance site functionality.
6
  Author: Chris Baldelomar
7
  Author URI: http://webplantmedia.com/
8
+ Version: 1.85
9
  License: GPLv2 or later
10
  */
11
 
12
+ define( 'WC_SHORTCODES_VERSION', '1.85' );
13
  define( 'WC_SHORTCODES_PREFIX', 'wc_shortcodes_' );
14
  define( '_WC_SHORTCODES_PREFIX', '_wc_shortcodes_' );
15
  define( 'WC_SHORTCODES_PLUGIN_URL', plugin_dir_url( __FILE__ ) );