Slider by Soliloquy – Responsive Image Slider for WordPress - Version 2.1.2

Version Description

  • Fixed a couple image cropping bugs.
  • Prevent upgrade option from showing for new users of Soliloquy.
Download this release

Release Info

Developer griffinjt
Plugin Icon 128x128 Slider by Soliloquy – Responsive Image Slider for WordPress
Version 2.1.2
Comparing to
See all releases

Code changes from version 2.1.0 to 2.1.2

includes/admin/common.php CHANGED
@@ -73,6 +73,19 @@ class Soliloquy_Common_Admin_Lite {
73
  return;
74
  }
75
 
 
 
 
 
 
 
 
 
 
 
 
 
 
76
  ?>
77
  <div class="error">
78
  <p><?php printf( __( 'Soliloquy Lite is now rocking v2! <strong>You need to upgrade your legacy v1 sliders to v2.</strong> <a href="%s">Click here to begin the upgrade process.</a>', 'soliloquy' ), add_query_arg( 'page', 'soliloquy-lite-settings', admin_url( 'edit.php?post_type=soliloquy' ) ) ); ?></p>
73
  return;
74
  }
75
 
76
+ // If the option exists for already checking for sliders from previous versions, bail.
77
+ $has_sliders = get_option( 'soliloquy_lite_upgrade' );
78
+ if ( $has_sliders ) {
79
+ return;
80
+ }
81
+
82
+ // If we have no sliders, only run this check once. Set option to prevent again.
83
+ $sliders = get_posts( array( 'post_type' => 'soliloquy', 'posts_per_page' => -1 ) );
84
+ if ( ! $sliders ) {
85
+ update_option( 'soliloquy_lite_upgrade', true );
86
+ return;
87
+ }
88
+
89
  ?>
90
  <div class="error">
91
  <p><?php printf( __( 'Soliloquy Lite is now rocking v2! <strong>You need to upgrade your legacy v1 sliders to v2.</strong> <a href="%s">Click here to begin the upgrade process.</a>', 'soliloquy' ), add_query_arg( 'page', 'soliloquy-lite-settings', admin_url( 'edit.php?post_type=soliloquy' ) ) ); ?></p>
includes/admin/settings.php CHANGED
@@ -76,6 +76,19 @@ class Soliloquy_Settings_Lite {
76
  return;
77
  }
78
 
 
 
 
 
 
 
 
 
 
 
 
 
 
79
  // Register the submenu.
80
  $this->hook = add_submenu_page(
81
  'edit.php?post_type=soliloquy',
76
  return;
77
  }
78
 
79
+ // If the option exists for already checking for sliders from previous versions, bail.
80
+ $has_sliders = get_option( 'soliloquy_lite_upgrade' );
81
+ if ( $has_sliders ) {
82
+ return;
83
+ }
84
+
85
+ // If we have no sliders, only run this check once. Set option to prevent again.
86
+ $sliders = get_posts( array( 'post_type' => 'soliloquy', 'posts_per_page' => -1 ) );
87
+ if ( ! $sliders ) {
88
+ update_option( 'soliloquy_lite_upgrade', true );
89
+ return;
90
+ }
91
+
92
  // Register the submenu.
93
  $this->hook = add_submenu_page(
94
  'edit.php?post_type=soliloquy',
includes/global/common.php CHANGED
@@ -171,7 +171,7 @@ class Soliloquy_Common_Lite {
171
  global $wpdb;
172
 
173
  // Get common vars.
174
- $args = func_get_args();
175
  $common = $this->get_image_info( $args );
176
 
177
  // Unpack variables if an array, otherwise return WP_Error.
171
  global $wpdb;
172
 
173
  // Get common vars.
174
+ $args = array( $url, $width, $height, $crop, $align, $quality, $retina );
175
  $common = $this->get_image_info( $args );
176
 
177
  // Unpack variables if an array, otherwise return WP_Error.
includes/global/shortcode.php CHANGED
@@ -117,6 +117,7 @@ class Soliloquy_Shortcode_Lite {
117
 
118
  // Load hooks and filters.
119
  add_shortcode( 'soliloquy', array( $this, 'shortcode' ) );
 
120
 
121
  }
122
 
@@ -150,6 +151,12 @@ class Soliloquy_Shortcode_Lite {
150
  $data = apply_filters( 'soliloquy_custom_slider_data', false, $atts, $post );
151
  }
152
 
 
 
 
 
 
 
153
  // Allow the data to be filtered before it is stored and used to create the slider output.
154
  $data = apply_filters( 'soliloquy_pre_data', $data, $slider_id );
155
 
@@ -225,6 +232,10 @@ class Soliloquy_Shortcode_Lite {
225
  // Increment the counter.
226
  $this->counter++;
227
 
 
 
 
 
228
  // Return the slider HTML.
229
  return apply_filters( 'soliloquy_output', $slider, $data );
230
 
117
 
118
  // Load hooks and filters.
119
  add_shortcode( 'soliloquy', array( $this, 'shortcode' ) );
120
+ add_filter( 'widget_text', 'do_shortcode' );
121
 
122
  }
123
 
151
  $data = apply_filters( 'soliloquy_custom_slider_data', false, $atts, $post );
152
  }
153
 
154
+ // If there is no data and the attribute used is an ID, try slug as well.
155
+ if ( ! $data && isset( $atts['id'] ) ) {
156
+ $slider_id = $atts['id'];
157
+ $data = is_preview() ? $this->base->_get_slider_by_slug( $slider_id ) : $this->base->get_slider_by_slug( $slider_id );
158
+ }
159
+
160
  // Allow the data to be filtered before it is stored and used to create the slider output.
161
  $data = apply_filters( 'soliloquy_pre_data', $data, $slider_id );
162
 
232
  // Increment the counter.
233
  $this->counter++;
234
 
235
+ // Add no JS fallback support.
236
+ $no_js = apply_filters( 'soliloquy_output_no_js', '<noscript><style type="text/css">#soliloquy-container-' . sanitize_html_class( $data['id'] ) . '{opacity:1}</style></noscript>', $data );
237
+ $slider .= $no_js;
238
+
239
  // Return the slider HTML.
240
  return apply_filters( 'soliloquy_output', $slider, $data );
241
 
readme.txt CHANGED
@@ -84,8 +84,16 @@ Soliloquy has many Addons that extend its default functionality to make it do in
84
 
85
  == Changelog ==
86
 
 
 
 
 
 
 
 
 
87
  = 2.1.0 =
88
- * Fix hover state error.
89
 
90
  = 2.0.9 =
91
  * Fixed navigation arrow regression (hidden by default and exposed on hover).
84
 
85
  == Changelog ==
86
 
87
+ = 2.1.2 =
88
+ * Fixed a couple image cropping bugs.
89
+ * Prevent upgrade option from showing for new users of Soliloquy.
90
+
91
+ = 2.1.1 =
92
+ * Fixed backwards compat bug with shortcodes that used IDs to output sliders.
93
+ * Added ability to parse shortcodes in widgets to prevent sliders from disappearing.
94
+
95
  = 2.1.0 =
96
+ * Fixed hover state error.
97
 
98
  = 2.0.9 =
99
  * Fixed navigation arrow regression (hidden by default and exposed on hover).
soliloquy-lite.php CHANGED
@@ -5,7 +5,7 @@
5
  * Description: Soliloquy is best responsive WordPress slider plugin. This is the lite version.
6
  * Author: Thomas Griffin
7
  * Author URI: http://thomasgriffinmedia.com
8
- * Version: 2.1.0
9
  * Text Domain: soliloquy
10
  * Domain Path: languages
11
  *
@@ -54,7 +54,7 @@ class Soliloquy_Lite {
54
  *
55
  * @var string
56
  */
57
- public $version = '2.1.0';
58
 
59
  /**
60
  * The name of the plugin.
5
  * Description: Soliloquy is best responsive WordPress slider plugin. This is the lite version.
6
  * Author: Thomas Griffin
7
  * Author URI: http://thomasgriffinmedia.com
8
+ * Version: 2.1.2
9
  * Text Domain: soliloquy
10
  * Domain Path: languages
11
  *
54
  *
55
  * @var string
56
  */
57
+ public $version = '2.1.2';
58
 
59
  /**
60
  * The name of the plugin.