Shortcodes Ultimate - Version 5.0.8

Version Description

Fixes

  • Fixed Live Preview, wasn't representing changed settings
  • Fixed [su_siblings], now it works again at top-level pages

Other

  • Various code improvements
  • New filters for gallery, slider, and carousel
  • Returned su_cmpt() and su_compatibility_mode_prefix() utils
Download this release

Release Info

Developer gn_themes
Plugin Icon 128x128 Shortcodes Ultimate
Version 5.0.8
Comparing to
See all releases

Code changes from version 5.0.7 to 5.0.8

admin/class-shortcodes-ultimate-admin-addons.php CHANGED
@@ -22,9 +22,9 @@ final class Shortcodes_Ultimate_Admin_Addons extends Shortcodes_Ultimate_Admin {
22
  * @param string $plugin_file The path of the main plugin file
23
  * @param string $plugin_version The current version of the plugin
24
  */
25
- public function __construct( $plugin_file, $plugin_version ) {
26
 
27
- parent::__construct( $plugin_file, $plugin_version );
28
 
29
  $this->api_url = 'https://getshortcodes.com/api/v1/add-ons/';
30
  $this->addons = array();
@@ -39,18 +39,18 @@ final class Shortcodes_Ultimate_Admin_Addons extends Shortcodes_Ultimate_Admin {
39
  *
40
  * @since 5.0.0
41
  */
42
- public function admin_menu() {
43
 
44
  /**
45
  * Submenu: Add-ons
46
  * admin.php?page=shortcodes-ultimate-addons
47
  */
48
  $this->add_submenu_page(
49
- 'shortcodes-ultimate',
50
  __( 'Add-ons', 'shortcodes-ultimate' ),
51
  __( 'Add-ons', 'shortcodes-ultimate' ),
52
  $this->get_capability(),
53
- 'shortcodes-ultimate-addons',
54
  array( $this, 'the_menu_page' )
55
  );
56
 
@@ -58,12 +58,12 @@ final class Shortcodes_Ultimate_Admin_Addons extends Shortcodes_Ultimate_Admin {
58
 
59
 
60
  /**
61
- * Add help tab and set help sidebar at Add-ons page.
62
  *
63
  * @since 5.0.0
64
  * @param WP_Screen $screen WP_Screen instance.
65
  */
66
- public function add_help_tab( $screen ) {
67
 
68
  if ( ! $this->is_component_page() ) {
69
  return;
22
  * @param string $plugin_file The path of the main plugin file
23
  * @param string $plugin_version The current version of the plugin
24
  */
25
+ public function __construct( $plugin_file, $plugin_version, $plugin_prefix ) {
26
 
27
+ parent::__construct( $plugin_file, $plugin_version, $plugin_prefix );
28
 
29
  $this->api_url = 'https://getshortcodes.com/api/v1/add-ons/';
30
  $this->addons = array();
39
  *
40
  * @since 5.0.0
41
  */
42
+ public function add_menu_pages() {
43
 
44
  /**
45
  * Submenu: Add-ons
46
  * admin.php?page=shortcodes-ultimate-addons
47
  */
48
  $this->add_submenu_page(
49
+ rtrim( $this->plugin_prefix, '-_' ),
50
  __( 'Add-ons', 'shortcodes-ultimate' ),
51
  __( 'Add-ons', 'shortcodes-ultimate' ),
52
  $this->get_capability(),
53
+ $this->plugin_prefix . 'addons',
54
  array( $this, 'the_menu_page' )
55
  );
56
 
58
 
59
 
60
  /**
61
+ * Add help tabs and set help sidebar at Add-ons page.
62
  *
63
  * @since 5.0.0
64
  * @param WP_Screen $screen WP_Screen instance.
65
  */
66
+ public function add_help_tabs( $screen ) {
67
 
68
  if ( ! $this->is_component_page() ) {
69
  return;
admin/class-shortcodes-ultimate-admin-settings.php CHANGED
@@ -20,13 +20,13 @@ final class Shortcodes_Ultimate_Admin_Settings extends Shortcodes_Ultimate_Admin
20
  private $plugin_settings;
21
 
22
  /**
23
- * The slug of the settings page.
24
  *
25
  * @since 5.0.0
26
  * @access private
27
- * @var array $settings_page The slug of the settings page.
28
  */
29
- private $settings_page;
30
 
31
  /**
32
  * Initialize the class and set its properties.
@@ -35,9 +35,9 @@ final class Shortcodes_Ultimate_Admin_Settings extends Shortcodes_Ultimate_Admin
35
  * @param string $plugin_file The path of the main plugin file
36
  * @param string $plugin_version The current version of the plugin
37
  */
38
- public function __construct( $plugin_file, $plugin_version ) {
39
 
40
- parent::__construct( $plugin_file, $plugin_version );
41
 
42
  $this->plugin_settings = array();
43
  $this->setting_defaults = array(
@@ -45,10 +45,10 @@ final class Shortcodes_Ultimate_Admin_Settings extends Shortcodes_Ultimate_Admin
45
  'title' => '',
46
  'type' => 'text',
47
  'description' => '',
48
- 'page' => 'shortcodes-ultimate-settings',
49
- 'section' => 'shortcodes-ultimate-general',
50
- 'group' => 'shortcodes-ultimate',
51
- 'callback' => array( $this, 'display_settings_field' ),
52
  'sanitize' => 'sanitize_text_field',
53
  );
54
 
@@ -59,18 +59,18 @@ final class Shortcodes_Ultimate_Admin_Settings extends Shortcodes_Ultimate_Admin
59
  *
60
  * @since 5.0.0
61
  */
62
- public function admin_menu() {
63
 
64
  /**
65
  * Submenu: Settings
66
  * admin.php?page=shortcodes-ultimate-settings
67
  */
68
  $this->add_submenu_page(
69
- 'shortcodes-ultimate',
70
  __( 'Settings', 'shortcodes-ultimate' ),
71
  __( 'Settings', 'shortcodes-ultimate' ),
72
  $this->get_capability(),
73
- 'shortcodes-ultimate-settings',
74
  array( $this, 'the_menu_page' )
75
  );
76
 
@@ -81,16 +81,16 @@ final class Shortcodes_Ultimate_Admin_Settings extends Shortcodes_Ultimate_Admin
81
  *
82
  * @since 5.0.0
83
  */
84
- public function register_settings() {
85
 
86
  /**
87
  * Add default settings section.
88
  */
89
  add_settings_section(
90
- 'shortcodes-ultimate-general',
91
  __( 'General settings', 'shortcodes-ultimate' ),
92
- array( $this, 'display_settings_section' ),
93
- 'shortcodes-ultimate-settings'
94
  );
95
 
96
  /**
@@ -120,36 +120,12 @@ final class Shortcodes_Ultimate_Admin_Settings extends Shortcodes_Ultimate_Admin
120
  }
121
 
122
  /**
123
- * Display settings section.
124
- *
125
- * @param mixed $args Settings section data.
126
- * @since 5.0.0
127
- */
128
- public function display_settings_section( $args ) {
129
-
130
- $section = str_replace( 'shortcodes-ultimate-', '', $args['id'] );
131
-
132
- $this->the_template( 'admin/partials/settings/sections/' . $section, $args );
133
-
134
- }
135
-
136
- /**
137
- * Display settings field.
138
- *
139
- * @param mixed $args The field data.
140
- * @since 5.0.0
141
- */
142
- public function display_settings_field( $args ) {
143
- $this->the_template( 'admin/partials/settings/fields/' . $args['type'], $args );
144
- }
145
-
146
- /**
147
- * Add help tab and set help sidebar at Add-ons page.
148
  *
149
  * @since 5.0.0
150
  * @param WP_Screen $screen WP_Screen instance.
151
  */
152
- public function add_help_tab( $screen ) {
153
 
154
  if ( ! $this->is_component_page() ) {
155
  return;
@@ -166,17 +142,22 @@ final class Shortcodes_Ultimate_Admin_Settings extends Shortcodes_Ultimate_Admin
166
  }
167
 
168
  /**
169
- * Callback function to sanitize checkbox value.
170
  *
171
- * @since 5.0.0
172
- * @param mixed $value String 'on' or null.
173
- * @return string Sanitized checkbox value ('on' or empty string '').
174
  */
175
- public function sanitize_checkbox( $value ) {
176
-
177
- $value = ( ! empty( $value ) && $value === 'on' ) ? 'on' : '';
 
 
 
 
 
 
178
 
179
- return $value;
180
 
181
  }
182
 
@@ -228,16 +209,4 @@ final class Shortcodes_Ultimate_Admin_Settings extends Shortcodes_Ultimate_Admin
228
 
229
  }
230
 
231
- /**
232
- * Callback function to sanitize prefix value.
233
- *
234
- * @since 5.0.1
235
- * @param string $prefix Prefix value.
236
- * @return string Sanitized string.
237
- * @see https://developer.wordpress.org/reference/functions/add_shortcode/ Source of the RegExp.
238
- */
239
- public function sanitize_prefix( $prefix ) {
240
- return preg_replace( '@[<>&/\[\]\x00-\x20="\']@', '', $prefix );
241
- }
242
-
243
  }
20
  private $plugin_settings;
21
 
22
  /**
23
+ * Default values for a single setting.
24
  *
25
  * @since 5.0.0
26
  * @access private
27
+ * @var array $setting_defaults Default values for a single setting.
28
  */
29
+ private $setting_defaults;
30
 
31
  /**
32
  * Initialize the class and set its properties.
35
  * @param string $plugin_file The path of the main plugin file
36
  * @param string $plugin_version The current version of the plugin
37
  */
38
+ public function __construct( $plugin_file, $plugin_version, $plugin_prefix ) {
39
 
40
+ parent::__construct( $plugin_file, $plugin_version, $plugin_prefix );
41
 
42
  $this->plugin_settings = array();
43
  $this->setting_defaults = array(
45
  'title' => '',
46
  'type' => 'text',
47
  'description' => '',
48
+ 'page' => $this->plugin_prefix . 'settings',
49
+ 'section' => $this->plugin_prefix . 'general',
50
+ 'group' => rtrim( $this->plugin_prefix, '-_' ),
51
+ 'callback' => array( $this, 'the_settings_field' ),
52
  'sanitize' => 'sanitize_text_field',
53
  );
54
 
59
  *
60
  * @since 5.0.0
61
  */
62
+ public function add_menu_pages() {
63
 
64
  /**
65
  * Submenu: Settings
66
  * admin.php?page=shortcodes-ultimate-settings
67
  */
68
  $this->add_submenu_page(
69
+ rtrim( $this->plugin_prefix, '-_' ),
70
  __( 'Settings', 'shortcodes-ultimate' ),
71
  __( 'Settings', 'shortcodes-ultimate' ),
72
  $this->get_capability(),
73
+ $this->plugin_prefix . 'settings',
74
  array( $this, 'the_menu_page' )
75
  );
76
 
81
  *
82
  * @since 5.0.0
83
  */
84
+ public function add_settings() {
85
 
86
  /**
87
  * Add default settings section.
88
  */
89
  add_settings_section(
90
+ $this->plugin_prefix . 'general',
91
  __( 'General settings', 'shortcodes-ultimate' ),
92
+ array( $this, 'the_settings_section' ),
93
+ $this->plugin_prefix . 'settings'
94
  );
95
 
96
  /**
120
  }
121
 
122
  /**
123
+ * Add help tabs and set help sidebar at Add-ons page.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
124
  *
125
  * @since 5.0.0
126
  * @param WP_Screen $screen WP_Screen instance.
127
  */
128
+ public function add_help_tabs( $screen ) {
129
 
130
  if ( ! $this->is_component_page() ) {
131
  return;
142
  }
143
 
144
  /**
145
+ * Filter to add action links at plugins screen.
146
  *
147
+ * @since 5.0.8
148
+ * @param array $links Default links.
 
149
  */
150
+ public function add_action_links( $links ) {
151
+
152
+ $plugin_links = array(
153
+ sprintf(
154
+ '<a href="%s">%s</a>',
155
+ esc_attr( $this->get_component_url() ),
156
+ esc_html( __( 'Settings', 'shortcodes-ultimate' ) )
157
+ ),
158
+ );
159
 
160
+ return array_merge( $plugin_links, $links );
161
 
162
  }
163
 
209
 
210
  }
211
 
 
 
 
 
 
 
 
 
 
 
 
 
212
  }
admin/class-shortcodes-ultimate-admin-shortcodes.php CHANGED
@@ -17,8 +17,8 @@ final class Shortcodes_Ultimate_Admin_Shortcodes extends Shortcodes_Ultimate_Adm
17
  * @param string $plugin_file The path of the main plugin file
18
  * @param string $plugin_version The current version of the plugin
19
  */
20
- public function __construct( $plugin_file, $plugin_version ) {
21
- parent::__construct( $plugin_file, $plugin_version );
22
  }
23
 
24
  /**
@@ -26,30 +26,40 @@ final class Shortcodes_Ultimate_Admin_Shortcodes extends Shortcodes_Ultimate_Adm
26
  *
27
  * @since 5.0.0
28
  */
29
- public function admin_menu() {
30
 
31
  /**
32
  * Submenu: Available shortcodes
33
  * admin.php?page=shortcodes-ultimate
34
  */
35
  $this->add_submenu_page(
36
- 'shortcodes-ultimate',
37
  __( 'Available shortcodes', 'shortcodes-ultimate' ),
38
  __( 'Available shortcodes', 'shortcodes-ultimate' ),
39
  $this->get_capability(),
40
- 'shortcodes-ultimate',
41
  array( $this, 'the_menu_page' )
42
  );
43
 
44
  }
45
 
46
  /**
47
- * Add help tab and set help sidebar at Add-ons page.
 
 
 
 
 
 
 
 
 
 
48
  *
49
  * @since 5.0.0
50
  * @param WP_Screen $screen WP_Screen instance.
51
  */
52
- public function add_help_tab( $screen ) {
53
 
54
  if ( ! $this->is_component_page() ) {
55
  return;
@@ -498,6 +508,26 @@ final class Shortcodes_Ultimate_Admin_Shortcodes extends Shortcodes_Ultimate_Adm
498
  return str_replace( array( '<b%value>', '</b>', '%su_skins_link%' ), '', $description );
499
  }
500
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
501
  /**
502
  * Helper to format output of implode function.
503
  *
17
  * @param string $plugin_file The path of the main plugin file
18
  * @param string $plugin_version The current version of the plugin
19
  */
20
+ public function __construct( $plugin_file, $plugin_version, $plugin_prefix ) {
21
+ parent::__construct( $plugin_file, $plugin_version, $plugin_prefix );
22
  }
23
 
24
  /**
26
  *
27
  * @since 5.0.0
28
  */
29
+ public function add_menu_pages() {
30
 
31
  /**
32
  * Submenu: Available shortcodes
33
  * admin.php?page=shortcodes-ultimate
34
  */
35
  $this->add_submenu_page(
36
+ rtrim( $this->plugin_prefix, '-_' ),
37
  __( 'Available shortcodes', 'shortcodes-ultimate' ),
38
  __( 'Available shortcodes', 'shortcodes-ultimate' ),
39
  $this->get_capability(),
40
+ rtrim( $this->plugin_prefix, '-_' ),
41
  array( $this, 'the_menu_page' )
42
  );
43
 
44
  }
45
 
46
  /**
47
+ * Display menu page.
48
+ *
49
+ * @since 5.0.8
50
+ * @return string Menu page markup.
51
+ */
52
+ public function the_menu_page() {
53
+ $this->the_template( 'admin/partials/pages/shortcodes' );
54
+ }
55
+
56
+ /**
57
+ * Add help tabs and set help sidebar at Add-ons page.
58
  *
59
  * @since 5.0.0
60
  * @param WP_Screen $screen WP_Screen instance.
61
  */
62
+ public function add_help_tabs( $screen ) {
63
 
64
  if ( ! $this->is_component_page() ) {
65
  return;
508
  return str_replace( array( '<b%value>', '</b>', '%su_skins_link%' ), '', $description );
509
  }
510
 
511
+ /**
512
+ * Filter to add action links at plugins screen.
513
+ *
514
+ * @since 5.0.8
515
+ * @param array $links Default links.
516
+ */
517
+ public function add_action_links( $links ) {
518
+
519
+ $plugin_links = array(
520
+ sprintf(
521
+ '<a href="%s">%s</a>',
522
+ esc_attr( $this->get_component_url() ),
523
+ esc_html( __( 'Shortcodes', 'shortcodes-ultimate' ) )
524
+ ),
525
+ );
526
+
527
+ return array_merge( $plugin_links, $links );
528
+
529
+ }
530
+
531
  /**
532
  * Helper to format output of implode function.
533
  *
admin/class-shortcodes-ultimate-admin-top-level.php CHANGED
@@ -17,17 +17,16 @@ final class Shortcodes_Ultimate_Admin_Top_Level extends Shortcodes_Ultimate_Admi
17
  * @param string $plugin_file The path of the main plugin file
18
  * @param string $plugin_version The current version of the plugin
19
  */
20
- public function __construct( $plugin_file, $plugin_version ) {
21
- parent::__construct( $plugin_file, $plugin_version );
22
  }
23
 
24
-
25
  /**
26
  * Add menu page
27
  *
28
  * @since 5.0.0
29
  */
30
- public function admin_menu() {
31
 
32
  // SVG icon (base64-encoded)
33
  $icon = apply_filters( 'su/admin/icon', 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGZpbGwtcnVsZT0iZXZlbm9kZCIgc3Ryb2tlLW1pdGVybGltaXQ9IjEuNDEiIHZpZXdCb3g9IjAgMCAyMCAyMCIgY2xpcC1ydWxlPSJldmVub2RkIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48cGF0aCBmaWxsPSIjZjBmNWZhIiBmaWxsLXJ1bGU9Im5vbnplcm8iIGQ9Ik04LjQ4IDIuNzV2Mi41SDUuMjV2OS41aDMuMjN2Mi41SDIuNzVWMi43NWg1Ljczem05LjI3IDE0LjVoLTUuNzN2LTIuNWgzLjIzdi05LjVoLTMuMjN2LTIuNWg1LjczdjE0LjV6Ii8+PC9zdmc+' );
@@ -40,7 +39,7 @@ final class Shortcodes_Ultimate_Admin_Top_Level extends Shortcodes_Ultimate_Admi
40
  __( 'Shortcodes Ultimate', 'shortcodes-ultimate' ),
41
  __( 'Shortcodes', 'shortcodes-ultimate' ),
42
  $this->get_capability(),
43
- 'shortcodes-ultimate',
44
  '__return_false',
45
  $icon,
46
  '80.11'
@@ -48,4 +47,14 @@ final class Shortcodes_Ultimate_Admin_Top_Level extends Shortcodes_Ultimate_Admi
48
 
49
  }
50
 
 
 
 
 
 
 
 
 
 
 
51
  }
17
  * @param string $plugin_file The path of the main plugin file
18
  * @param string $plugin_version The current version of the plugin
19
  */
20
+ public function __construct( $plugin_file, $plugin_version, $plugin_prefix ) {
21
+ parent::__construct( $plugin_file, $plugin_version, $plugin_prefix );
22
  }
23
 
 
24
  /**
25
  * Add menu page
26
  *
27
  * @since 5.0.0
28
  */
29
+ public function add_menu_pages() {
30
 
31
  // SVG icon (base64-encoded)
32
  $icon = apply_filters( 'su/admin/icon', 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGZpbGwtcnVsZT0iZXZlbm9kZCIgc3Ryb2tlLW1pdGVybGltaXQ9IjEuNDEiIHZpZXdCb3g9IjAgMCAyMCAyMCIgY2xpcC1ydWxlPSJldmVub2RkIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48cGF0aCBmaWxsPSIjZjBmNWZhIiBmaWxsLXJ1bGU9Im5vbnplcm8iIGQ9Ik04LjQ4IDIuNzV2Mi41SDUuMjV2OS41aDMuMjN2Mi41SDIuNzVWMi43NWg1Ljczem05LjI3IDE0LjVoLTUuNzN2LTIuNWgzLjIzdi05LjVoLTMuMjN2LTIuNWg1LjczdjE0LjV6Ii8+PC9zdmc+' );
39
  __( 'Shortcodes Ultimate', 'shortcodes-ultimate' ),
40
  __( 'Shortcodes', 'shortcodes-ultimate' ),
41
  $this->get_capability(),
42
+ rtrim( $this->plugin_prefix, '-_' ),
43
  '__return_false',
44
  $icon,
45
  '80.11'
47
 
48
  }
49
 
50
+ /**
51
+ * Display menu page.
52
+ *
53
+ * @since 5.0.8
54
+ * @return string Menu page markup.
55
+ */
56
+ public function the_menu_page() {
57
+ $this->the_template( 'admin/partials/pages/shortcodes' );
58
+ }
59
+
60
  }
admin/class-shortcodes-ultimate-admin.php CHANGED
@@ -28,6 +28,15 @@ abstract class Shortcodes_Ultimate_Admin {
28
  */
29
  protected $plugin_version;
30
 
 
 
 
 
 
 
 
 
 
31
  /**
32
  * The URL of the plugin folder.
33
  *
@@ -98,11 +107,13 @@ abstract class Shortcodes_Ultimate_Admin {
98
  * @access protected
99
  * @param string $plugin_file The path of the main plugin file.
100
  * @param string $plugin_version The current version of the plugin.
 
101
  */
102
- protected function __construct( $plugin_file, $plugin_version ) {
103
 
104
  $this->plugin_file = $plugin_file;
105
  $this->plugin_version = $plugin_version;
 
106
  $this->plugin_url = plugin_dir_url( $plugin_file );
107
  $this->plugin_path = plugin_dir_path( $plugin_file );
108
  $this->capability = 'manage_options';
@@ -114,11 +125,18 @@ abstract class Shortcodes_Ultimate_Admin {
114
  }
115
 
116
  /**
117
- * Add menu page
118
  *
119
  * @since 5.0.0
120
  */
121
- public function admin_menu() {}
 
 
 
 
 
 
 
122
 
123
  /**
124
  * Enqueue JavaScript(s) and Stylesheet(s) for the component.
@@ -191,17 +209,36 @@ abstract class Shortcodes_Ultimate_Admin {
191
  $page = sanitize_title( $_GET['page'], false );
192
 
193
  // Replace plugin slug with template prefix
194
- $page = str_replace( 'shortcodes-ultimate-', '', $page );
195
-
196
- // Load "Available shortcodes" page
197
- if ( $page === 'shortcodes-ultimate' ) {
198
- $page = 'shortcodes';
199
- }
200
 
201
  $this->the_template( 'admin/partials/pages/' . $page );
202
 
203
  }
204
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
205
  /**
206
  * Helper function to check component's menu page hook_suffix
207
  *
@@ -344,6 +381,29 @@ abstract class Shortcodes_Ultimate_Admin {
344
  return $this->component_url;
345
  }
346
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
347
  /**
348
  * Utility function to get specified template by it's name.
349
  *
28
  */
29
  protected $plugin_version;
30
 
31
+ /**
32
+ * The prefix of the plugin.
33
+ *
34
+ * @since 5.0.8
35
+ * @access protected
36
+ * @var string $plugin_prefix The prefix of the plugin.
37
+ */
38
+ protected $plugin_prefix;
39
+
40
  /**
41
  * The URL of the plugin folder.
42
  *
107
  * @access protected
108
  * @param string $plugin_file The path of the main plugin file.
109
  * @param string $plugin_version The current version of the plugin.
110
+ * @param string $plugin_prefix The prefix of the plugin.
111
  */
112
+ protected function __construct( $plugin_file, $plugin_version, $plugin_prefix ) {
113
 
114
  $this->plugin_file = $plugin_file;
115
  $this->plugin_version = $plugin_version;
116
+ $this->plugin_prefix = $plugin_prefix;
117
  $this->plugin_url = plugin_dir_url( $plugin_file );
118
  $this->plugin_path = plugin_dir_path( $plugin_file );
119
  $this->capability = 'manage_options';
125
  }
126
 
127
  /**
128
+ * Register menu pages.
129
  *
130
  * @since 5.0.0
131
  */
132
+ public function add_menu_pages() {}
133
+
134
+ /**
135
+ * Register settings.
136
+ *
137
+ * @since 5.0.8
138
+ */
139
+ public function add_settings() {}
140
 
141
  /**
142
  * Enqueue JavaScript(s) and Stylesheet(s) for the component.
209
  $page = sanitize_title( $_GET['page'], false );
210
 
211
  // Replace plugin slug with template prefix
212
+ $page = str_replace( $this->plugin_prefix, '', $page );
 
 
 
 
 
213
 
214
  $this->the_template( 'admin/partials/pages/' . $page );
215
 
216
  }
217
 
218
+ /**
219
+ * Display settings section.
220
+ *
221
+ * @param mixed $args Settings section data.
222
+ * @since 5.0.8
223
+ */
224
+ public function the_settings_section( $args ) {
225
+
226
+ $section = str_replace( $this->plugin_prefix, '', $args['id'] );
227
+
228
+ $this->the_template( 'admin/partials/settings/sections/' . $section, $args );
229
+
230
+ }
231
+
232
+ /**
233
+ * Display settings field.
234
+ *
235
+ * @param mixed $args The field data.
236
+ * @since 5.0.8
237
+ */
238
+ public function the_settings_field( $args ) {
239
+ $this->the_template( 'admin/partials/settings/fields/' . $args['type'], $args );
240
+ }
241
+
242
  /**
243
  * Helper function to check component's menu page hook_suffix
244
  *
381
  return $this->component_url;
382
  }
383
 
384
+ /**
385
+ * Callback function to sanitize checkbox value.
386
+ *
387
+ * @since 5.0.0
388
+ * @param mixed $value String 'on' or null.
389
+ * @return string Sanitized checkbox value ('on' or empty string '').
390
+ */
391
+ public function sanitize_checkbox( $value ) {
392
+ return ! empty( $value ) && 'on' === $value ? 'on' : '';
393
+ }
394
+
395
+ /**
396
+ * Callback function to sanitize prefix value.
397
+ *
398
+ * @since 5.0.1
399
+ * @param string $prefix Prefix value.
400
+ * @return string Sanitized string.
401
+ * @see https://developer.wordpress.org/reference/functions/add_shortcode/ Source of the RegExp.
402
+ */
403
+ public function sanitize_prefix( $prefix ) {
404
+ return preg_replace( '@[<>&/\[\]\x00-\x20="\']@', '', $prefix );
405
+ }
406
+
407
  /**
408
  * Utility function to get specified template by it's name.
409
  *
admin/partials/pages/settings.php CHANGED
@@ -8,8 +8,8 @@
8
 
9
  <form action="options.php" method="post">
10
 
11
- <?php settings_fields( 'shortcodes-ultimate' ); ?>
12
- <?php do_settings_sections( 'shortcodes-ultimate-settings' ); ?>
13
  <?php submit_button(); ?>
14
 
15
  </form>
8
 
9
  <form action="options.php" method="post">
10
 
11
+ <?php settings_fields( rtrim( $this->plugin_prefix, '-_' ) ); ?>
12
+ <?php do_settings_sections( $this->plugin_prefix . 'settings' ); ?>
13
  <?php submit_button(); ?>
14
 
15
  </form>
admin/partials/settings/fields/css.php CHANGED
@@ -5,15 +5,33 @@
5
  <p class="description"><?php echo $data['description']; ?></p>
6
 
7
  <h4 class="title"><?php _e( 'Available variables', 'shortcodes-ultimate' ); ?></h4>
8
- <ul>
9
- <li><code>%home_url%</code> - <?php printf( '%s (%s)', __( 'the URL of the site home page', 'shortcodes-ultimate' ), __( 'with trailing slash', 'shortcodes-ultimate' ) ); ?></li>
10
- <li><code>%theme_url%</code> - <?php printf( '%s (%s)', __( 'the URL of the directory of the current theme', 'shortcodes-ultimate' ), __( 'with trailing slash', 'shortcodes-ultimate' ) ); ?></li>
11
- <li><code>%plugin_url%</code> - <?php printf( '%s (%s)', __( 'the URL of the directory of the plugin', 'shortcodes-ultimate' ), __( 'with trailing slash', 'shortcodes-ultimate' ) ); ?></li>
12
- </ul>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
13
 
14
  <h4 class="title"><?php _e( 'More information', 'shortcodes-ultimate' ); ?></h4>
15
 
16
  <ul class="ul-disc">
17
- <li><?php _e( 'See help tab at the top right corner of this page for more information.', 'shortcodes-ultimate' ); ?></li>
18
- <li><?php printf( __( 'Open %s file to see default styles.', 'shortcodes-ultimate' ), '<a href="' . $this->plugin_url . 'includes/css/shortcodes.css" target="_blank">shortcodes.css</a>' ); ?></li>
 
19
  </ul>
5
  <p class="description"><?php echo $data['description']; ?></p>
6
 
7
  <h4 class="title"><?php _e( 'Available variables', 'shortcodes-ultimate' ); ?></h4>
8
+ <table class="widefat striped" style="width:auto">
9
+ <thead>
10
+ <tr>
11
+ <td><?php esc_html_e( 'Variable', 'shortcodes-ultimate' ); ?></td>
12
+ <td><?php esc_html_e( 'Will be replaced with', 'shortcodes-ultimate' ); ?>&hellip;</td>
13
+ </tr>
14
+ </thead>
15
+ <tbody>
16
+ <tr>
17
+ <td><code contenteditable>%home_url%</code></td>
18
+ <td><?php printf( '%s (%s)', __( 'the URL of the site home page', 'shortcodes-ultimate' ), __( 'with trailing slash', 'shortcodes-ultimate' ) ); ?></td>
19
+ </tr>
20
+ <tr>
21
+ <td><code contenteditable>%theme_url%</code></td>
22
+ <td><?php printf( '%s (%s)', __( 'the URL of the directory of the current theme', 'shortcodes-ultimate' ), __( 'with trailing slash', 'shortcodes-ultimate' ) ); ?></td>
23
+ </tr>
24
+ <tr>
25
+ <td><code contenteditable>%plugin_url%</code></td>
26
+ <td><?php printf( '%s (%s)', __( 'the URL of the directory of the plugin', 'shortcodes-ultimate' ), __( 'with trailing slash', 'shortcodes-ultimate' ) ); ?></td>
27
+ </tr>
28
+ </tbody>
29
+ </table>
30
 
31
  <h4 class="title"><?php _e( 'More information', 'shortcodes-ultimate' ); ?></h4>
32
 
33
  <ul class="ul-disc">
34
+ <?php // Translators: %s - link to the shortcodes.css file ?>
35
+ <li><?php printf( __( 'Open %s file to see default styles', 'shortcodes-ultimate' ), '<a href="' . $this->plugin_url . 'includes/css/shortcodes.css" target="_blank">shortcodes.css</a>' ); ?></li>
36
+ <li><?php esc_html_e( 'Help article', 'shortcodes-ultimate' ); ?>: <a href="http://docs.getshortcodes.com/article/33-custom-css-editor" target="_blank"><?php esc_html_e( 'How to use Custom CSS editor', 'shortcodes-ultimate' ); ?></a></li>
37
  </ul>
inc/core/generator.php CHANGED
@@ -183,7 +183,7 @@ class Su_Generator {
183
  // Output results
184
  do_action( 'su/generator/preview/before' );
185
  echo '<h5>' . __( 'Preview', 'shortcodes-ultimate' ) . '</h5>';
186
- echo do_shortcode( wp_kses_post( $_POST['shortcode'] ) );
187
  echo '<div style="clear:both"></div>';
188
  do_action( 'su/generator/preview/after' );
189
  die();
183
  // Output results
184
  do_action( 'su/generator/preview/before' );
185
  echo '<h5>' . __( 'Preview', 'shortcodes-ultimate' ) . '</h5>';
186
+ echo do_shortcode( wp_kses_post( wp_unslash( $_POST['shortcode'] ) ) );
187
  echo '<div style="clear:both"></div>';
188
  do_action( 'su/generator/preview/after' );
189
  die();
includes/class-shortcodes-ultimate.php CHANGED
@@ -38,6 +38,15 @@ class Shortcodes_Ultimate {
38
  */
39
  private $plugin_path;
40
 
 
 
 
 
 
 
 
 
 
41
  /**
42
  * Class instance.
43
  *
@@ -88,12 +97,14 @@ class Shortcodes_Ultimate {
88
  * @since 5.0.0
89
  * @param string $plugin_file The path to the main plugin file.
90
  * @param string $plugin_version The current version of the plugin.
 
91
  */
92
- public function __construct( $plugin_file, $plugin_version ) {
93
 
94
  $this->plugin_file = $plugin_file;
95
  $this->plugin_version = $plugin_version;
96
  $this->plugin_path = plugin_dir_path( $plugin_file );
 
97
 
98
  $this->load_dependencies();
99
  $this->define_admin_hooks();
@@ -161,9 +172,11 @@ class Shortcodes_Ultimate {
161
  */
162
  require_once $this->plugin_path . 'includes/shortcodes/_all.php';
163
 
 
164
  // foreach ( glob( $this->plugin_path . 'includes/shortcodes/*.php' ) as $shortcode_file ) {
165
  // require_once $shortcode_file;
166
  // }
 
167
 
168
  }
169
 
@@ -188,48 +201,79 @@ class Shortcodes_Ultimate {
188
  * Top-level menu: Shortcodes
189
  * admin.php?page=shortcodes-ultimate
190
  */
191
- $this->top_level_menu = new Shortcodes_Ultimate_Admin_Top_Level( $this->plugin_file, $this->plugin_version );
 
 
 
 
192
 
193
- add_action( 'admin_menu', array( $this->top_level_menu, 'admin_menu' ), 5 );
194
 
195
 
196
  /**
197
  * Submenu: Available shortcodes
198
  * admin.php?page=shortcodes-ultimate
199
  */
200
- $this->shortcodes_menu = new Shortcodes_Ultimate_Admin_Shortcodes( $this->plugin_file, $this->plugin_version );
201
-
202
- add_action( 'admin_menu', array( $this->shortcodes_menu, 'admin_menu' ), 5 );
203
- add_action( 'current_screen', array( $this->shortcodes_menu, 'add_help_tab' ) );
204
- add_action( 'admin_enqueue_scripts', array( $this->shortcodes_menu, 'enqueue_scripts' ) );
 
 
 
 
 
 
 
 
 
 
205
 
206
 
207
  /**
208
  * Submenu: Settings
209
  * admin.php?page=shortcodes-ultimate-settings
210
  */
211
- $this->settings_menu = new Shortcodes_Ultimate_Admin_Settings( $this->plugin_file, $this->plugin_version );
212
-
213
- add_action( 'admin_menu', array( $this->settings_menu, 'admin_menu' ), 20 );
214
- add_action( 'admin_init', array( $this->settings_menu, 'register_settings' ) );
215
- add_action( 'current_screen', array( $this->settings_menu, 'add_help_tab' ) );
 
 
 
 
 
 
 
 
 
 
216
 
217
 
218
  /**
219
  * Submenu: Add-ons
220
  * admin.php?page=shortcodes-ultimate-addons
221
  */
222
- $this->addons_menu = new Shortcodes_Ultimate_Admin_Addons( $this->plugin_file, $this->plugin_version );
 
 
 
 
223
 
224
- add_action( 'admin_menu', array( $this->addons_menu, 'admin_menu' ), 30 );
225
- add_action( 'admin_enqueue_scripts', array( $this->addons_menu, 'enqueue_scripts' ) );
226
- add_action( 'current_screen', array( $this->addons_menu, 'add_help_tab' ) );
227
 
228
 
229
  /**
230
  * Notice: Rate plugin
231
  */
232
- $this->rate_notice = new Shortcodes_Ultimate_Notice_Rate( 'rate', $this->plugin_path . 'admin/partials/notices/rate.php' );
 
 
 
233
 
234
  add_action( 'load-plugins.php', array( $this->rate_notice, 'defer_first_time' ) );
235
  add_action( 'admin_notices', array( $this->rate_notice, 'display_notice' ) );
38
  */
39
  private $plugin_path;
40
 
41
+ /**
42
+ * The prefix of the plugin.
43
+ *
44
+ * @since 5.0.8
45
+ * @access private
46
+ * @var string $plugin_prefix The prefix of the plugin.
47
+ */
48
+ private $plugin_prefix;
49
+
50
  /**
51
  * Class instance.
52
  *
97
  * @since 5.0.0
98
  * @param string $plugin_file The path to the main plugin file.
99
  * @param string $plugin_version The current version of the plugin.
100
+ * @param string $plugin_prefix The prefix of the plugin.
101
  */
102
+ public function __construct( $plugin_file, $plugin_version, $plugin_prefix ) {
103
 
104
  $this->plugin_file = $plugin_file;
105
  $this->plugin_version = $plugin_version;
106
  $this->plugin_path = plugin_dir_path( $plugin_file );
107
+ $this->plugin_prefix = $plugin_prefix;
108
 
109
  $this->load_dependencies();
110
  $this->define_admin_hooks();
172
  */
173
  require_once $this->plugin_path . 'includes/shortcodes/_all.php';
174
 
175
+ // phpcs:disable
176
  // foreach ( glob( $this->plugin_path . 'includes/shortcodes/*.php' ) as $shortcode_file ) {
177
  // require_once $shortcode_file;
178
  // }
179
+ // phpcs:enable
180
 
181
  }
182
 
201
  * Top-level menu: Shortcodes
202
  * admin.php?page=shortcodes-ultimate
203
  */
204
+ $this->top_level_menu = new Shortcodes_Ultimate_Admin_Top_Level(
205
+ $this->plugin_file,
206
+ $this->plugin_version,
207
+ $this->plugin_prefix
208
+ );
209
 
210
+ add_action( 'admin_menu', array( $this->top_level_menu, 'add_menu_pages' ), 5 );
211
 
212
 
213
  /**
214
  * Submenu: Available shortcodes
215
  * admin.php?page=shortcodes-ultimate
216
  */
217
+ $this->shortcodes_menu = new Shortcodes_Ultimate_Admin_Shortcodes(
218
+ $this->plugin_file,
219
+ $this->plugin_version,
220
+ $this->plugin_prefix
221
+ );
222
+
223
+ add_action( 'admin_menu', array( $this->shortcodes_menu, 'add_menu_pages' ), 5 );
224
+ add_action( 'current_screen', array( $this->shortcodes_menu, 'add_help_tabs' ) );
225
+ add_action( 'admin_enqueue_scripts', array( $this->shortcodes_menu, 'enqueue_scripts' ) );
226
+ add_filter(
227
+ 'plugin_action_links_' . plugin_basename( $this->plugin_file ),
228
+ array( $this->shortcodes_menu, 'add_action_links' ),
229
+ 20,
230
+ 1
231
+ );
232
 
233
 
234
  /**
235
  * Submenu: Settings
236
  * admin.php?page=shortcodes-ultimate-settings
237
  */
238
+ $this->settings_menu = new Shortcodes_Ultimate_Admin_Settings(
239
+ $this->plugin_file,
240
+ $this->plugin_version,
241
+ $this->plugin_prefix
242
+ );
243
+
244
+ add_action( 'admin_menu', array( $this->settings_menu, 'add_menu_pages' ), 20 );
245
+ add_action( 'admin_init', array( $this->settings_menu, 'add_settings' ) );
246
+ add_action( 'current_screen', array( $this->settings_menu, 'add_help_tabs' ) );
247
+ add_filter(
248
+ 'plugin_action_links_' . plugin_basename( $this->plugin_file ),
249
+ array( $this->settings_menu, 'add_action_links' ),
250
+ 10,
251
+ 1
252
+ );
253
 
254
 
255
  /**
256
  * Submenu: Add-ons
257
  * admin.php?page=shortcodes-ultimate-addons
258
  */
259
+ $this->addons_menu = new Shortcodes_Ultimate_Admin_Addons(
260
+ $this->plugin_file,
261
+ $this->plugin_version,
262
+ $this->plugin_prefix
263
+ );
264
 
265
+ add_action( 'admin_menu', array( $this->addons_menu, 'add_menu_pages' ), 30 );
266
+ add_action( 'admin_enqueue_scripts', array( $this->addons_menu, 'enqueue_scripts' ) );
267
+ add_action( 'current_screen', array( $this->addons_menu, 'add_help_tabs' ) );
268
 
269
 
270
  /**
271
  * Notice: Rate plugin
272
  */
273
+ $this->rate_notice = new Shortcodes_Ultimate_Notice_Rate(
274
+ 'rate',
275
+ $this->plugin_path . 'admin/partials/notices/rate.php'
276
+ );
277
 
278
  add_action( 'load-plugins.php', array( $this->rate_notice, 'defer_first_time' ) );
279
  add_action( 'admin_notices', array( $this->rate_notice, 'display_notice' ) );
includes/deprecated/functions.php CHANGED
@@ -25,6 +25,23 @@ function su_scattr( $value ) {
25
  return Su_Tools::do_attr( $value );
26
  }
27
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
28
 
29
  /**
30
  * Custom do_shortcode function for nested shortcodes
25
  return Su_Tools::do_attr( $value );
26
  }
27
 
28
+ /**
29
+ * Shortcode names prefix in compatibility mode
30
+ *
31
+ * @deprecated 5.0.5 Replaced with more clear name su_get_shortcode_prefix().
32
+ */
33
+ function su_compatibility_mode_prefix() {
34
+ return su_get_shortcode_prefix();
35
+ }
36
+
37
+ /**
38
+ * Shortcut for su_compatibility_mode_prefix()
39
+ *
40
+ * @deprecated 5.0.5 Replaced with more clear name su_get_shortcode_prefix().
41
+ */
42
+ function su_cmpt() {
43
+ return su_get_shortcode_prefix();
44
+ }
45
 
46
  /**
47
  * Custom do_shortcode function for nested shortcodes
includes/shortcodes/carousel.php CHANGED
@@ -164,8 +164,10 @@ function su_shortcode_carousel( $atts = null, $content = null ) {
164
  'speed' => 600,
165
  'class' => ''
166
  ), $atts, 'carousel' );
167
- // Get slides
168
- $slides = (array) su_get_slides( $atts );
 
 
169
  // Loop slides
170
  if ( count( $slides ) ) {
171
  // Prepare unique ID
164
  'speed' => 600,
165
  'class' => ''
166
  ), $atts, 'carousel' );
167
+
168
+ $slides = su_get_slides( $atts );
169
+ $slides = apply_filters( 'su/shortcode/carousel/slides', $slides, $atts );
170
+
171
  // Loop slides
172
  if ( count( $slides ) ) {
173
  // Prepare unique ID
includes/shortcodes/custom_gallery.php CHANGED
@@ -98,7 +98,10 @@ function su_shortcode_custom_gallery( $atts = null, $content = null ) {
98
  'target' => 'self',
99
  'class' => ''
100
  ), $atts, 'custom_gallery' );
101
- $slides = (array) su_get_slides( $atts );
 
 
 
102
  // Loop slides
103
  if ( count( $slides ) ) {
104
  // Prepare links target
98
  'target' => 'self',
99
  'class' => ''
100
  ), $atts, 'custom_gallery' );
101
+
102
+ $slides = su_get_slides( $atts );
103
+ $slides = apply_filters( 'su/shortcode/custom_gallery/slides', $slides, $atts );
104
+
105
  // Loop slides
106
  if ( count( $slides ) ) {
107
  // Prepare links target
includes/shortcodes/siblings.php CHANGED
@@ -34,7 +34,7 @@ function su_shortcode_siblings( $atts = null, $content = null ) {
34
 
35
  global $post;
36
 
37
- if ( empty( $post ) || empty( $post->post_parent ) ) {
38
  return;
39
  }
40
 
34
 
35
  global $post;
36
 
37
+ if ( ! ( $post instanceof WP_Post ) ) {
38
  return;
39
  }
40
 
includes/shortcodes/slider.php CHANGED
@@ -143,8 +143,10 @@ function su_shortcode_slider( $atts = null, $content = null ) {
143
  'speed' => 600,
144
  'class' => ''
145
  ), $atts, 'slider' );
146
- // Get slides
147
- $slides = (array) su_get_slides( $atts );
 
 
148
  // Loop slides
149
  if ( count( $slides ) ) {
150
  // Prepare unique ID
143
  'speed' => 600,
144
  'class' => ''
145
  ), $atts, 'slider' );
146
+
147
+ $slides = su_get_slides( $atts );
148
+ $slides = apply_filters( 'su/shortcode/custom_gallery/slides', $slides, $atts );
149
+
150
  // Loop slides
151
  if ( count( $slides ) ) {
152
  // Prepare unique ID
readme.txt CHANGED
@@ -5,7 +5,7 @@ Donate link: https://paypal.me/anovladimir
5
  Tags: shortcode, toggle, columns, button, slider, video, map, visual, responsive, shortcodes, youtube, vimeo, audio, mp3, tabs, jquery, box, accordion, toggle, pullquote, list, image, gallery, navigation, permalink, feed, rss, members, membership, guests, carousel, icons, rtl, multilingual
6
  Requires at least: 3.5
7
  Requires PHP: 5.2.4
8
- Tested up to: 4.9
9
  Stable tag: trunk
10
 
11
  A comprehensive collection of visual components for your site
@@ -15,26 +15,61 @@ A comprehensive collection of visual components for your site
15
 
16
  [Shortcodes Ultimate](https://getshortcodes.com/) is a comprehensive collection of various visual and functional elements, which you can use in the post editor, text widgets or even in template files. Using Shortcodes Ultimate you can easily create tabs, buttons, boxes, sliders and carousels, responsive videos and much, much more.
17
 
18
- = Feature highlights =
19
- * [50+ beautiful shortcodes](https://getshortcodes.com/shortcodes/)
 
 
20
  * 1-click shortcode insertion with live preview
21
  * Works with any theme
22
  * Modern responsive design
23
- * [Comprehensive documentation](http://docs.getshortcodes.com/)
24
  * Custom CSS editor
25
  * Custom widget
26
- * Translated into 9 languages
27
  * RTL support
28
- * Powerful API
 
 
 
 
 
 
 
 
 
 
 
29
 
30
  = Check out premium add-ons! =
 
31
  * [Extra Shortcodes](https://getshortcodes.com/add-ons/extra-shortcodes/) - 15+ additional shortcodes
32
- * [Additional Skins](https://getshortcodes.com/add-ons/additional-skins/) - 60+ additional skins for plugin shortcodes
33
- * [Shortcode Creator](https://getshortcodes.com/add-ons/shortcode-creator/) - allows you to create your own custom shortcodes
34
  * __[Add-ons Bundle](https://getshortcodes.com/add-ons/add-ons-bundle/)__ - All-in-one!
35
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
36
  = Thanks to these great guys for contribution =
37
- * [Detailed reviews by advanced users](http://docs.getshortcodes.com/article/84-external-resources)
 
38
  * Dmitry Semenov - [Magnific Popup jQuery plugin](http://dimsemenov.com/plugins/magnific-popup/)
39
  * Craig Thompson - [qTip jQuery plugin](http://qtip2.com/)
40
  * Vladimir Kharlampidi - [Swiper jQuery plugin](http://www.idangero.us/sliders/swiper/)
@@ -47,16 +82,24 @@ A comprehensive collection of visual components for your site
47
  * cs_cz locale: [Punc00](http://nuze.cz/)
48
  * sv_se locale: [Javier Marcilla](http://ninjaseo.es/)
49
 
 
50
  == Installation ==
51
 
52
- Unzip plugin file and upload "shortcodes-ultimate" folder under your "/wp-content/plugins/" directory.
 
 
 
 
53
 
54
- Resulted plugin path should be:
55
- "/wp-content/plugins/shortcodes-ultimate/**"
56
 
57
- Activate the plugin at "Dashboard – Plugins" administration page.
58
 
59
- [Complete installation guide](http://docs.getshortcodes.com/article/13-plugin-installation).
 
 
 
 
60
 
61
 
62
  == Screenshots ==
@@ -106,6 +149,27 @@ For help with premium add-ons, please [open new support ticket](https://getshort
106
 
107
  == Changelog ==
108
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
109
  = 5.0.7 =
110
 
111
  **Security update**
5
  Tags: shortcode, toggle, columns, button, slider, video, map, visual, responsive, shortcodes, youtube, vimeo, audio, mp3, tabs, jquery, box, accordion, toggle, pullquote, list, image, gallery, navigation, permalink, feed, rss, members, membership, guests, carousel, icons, rtl, multilingual
6
  Requires at least: 3.5
7
  Requires PHP: 5.2.4
8
+ Tested up to: 5.0
9
  Stable tag: trunk
10
 
11
  A comprehensive collection of visual components for your site
15
 
16
  [Shortcodes Ultimate](https://getshortcodes.com/) is a comprehensive collection of various visual and functional elements, which you can use in the post editor, text widgets or even in template files. Using Shortcodes Ultimate you can easily create tabs, buttons, boxes, sliders and carousels, responsive videos and much, much more.
17
 
18
+
19
+ = Features =
20
+
21
+ * 50+ beautiful shortcodes
22
  * 1-click shortcode insertion with live preview
23
  * Works with any theme
24
  * Modern responsive design
25
+ * Documentation
26
  * Custom CSS editor
27
  * Custom widget
28
+ * Translation-ready
29
  * RTL support
30
+ * Developer-friendly
31
+
32
+
33
+ = Links =
34
+
35
+ * [Available shortcodes](https://getshortcodes.com/shortcodes/)
36
+ * [Add-ons](https://getshortcodes.com/add-ons/)
37
+ * [Documentation](https://docs.getshortcodes.com)
38
+ * [Support forum](https://wordpress.org/support/plugin/shortcodes-ultimate)
39
+ * [Premium support](https://getshortcodes.com/support/)
40
+ * [GitHub](https://github.com/vanokhin/shortcodes-ultimate)
41
+
42
 
43
  = Check out premium add-ons! =
44
+
45
  * [Extra Shortcodes](https://getshortcodes.com/add-ons/extra-shortcodes/) - 15+ additional shortcodes
46
+ * [Additional Skins](https://getshortcodes.com/add-ons/additional-skins/) - 60+ additional skins
47
+ * [Shortcode Creator](https://getshortcodes.com/add-ons/shortcode-creator/) - create your own custom shortcodes
48
  * __[Add-ons Bundle](https://getshortcodes.com/add-ons/add-ons-bundle/)__ - All-in-one!
49
 
50
+
51
+ = Available Shortcodes =
52
+
53
+ `
54
+ Heading Tabs Spoiler Accordion
55
+ Divider Spacer Highlight Label
56
+ Quote Pullquote Dropcap Columns
57
+ List Button Service Box
58
+ Note Expand Lightbox Tooltip
59
+ Private YouTube Vimeo Dailymotion
60
+ Audio Video Table Permalink
61
+ Members Guests RSS Menu
62
+ Sub pages Siblings Document Google map
63
+ Slider Carousel Gallery Posts
64
+ Dummy text Dummy image Animation Meta data
65
+ User data Post data Template QR code
66
+ Scheduler
67
+ `
68
+
69
+
70
  = Thanks to these great guys for contribution =
71
+
72
+ * [Reviews by advanced users](http://docs.getshortcodes.com/article/84-external-resources)
73
  * Dmitry Semenov - [Magnific Popup jQuery plugin](http://dimsemenov.com/plugins/magnific-popup/)
74
  * Craig Thompson - [qTip jQuery plugin](http://qtip2.com/)
75
  * Vladimir Kharlampidi - [Swiper jQuery plugin](http://www.idangero.us/sliders/swiper/)
82
  * cs_cz locale: [Punc00](http://nuze.cz/)
83
  * sv_se locale: [Javier Marcilla](http://ninjaseo.es/)
84
 
85
+
86
  == Installation ==
87
 
88
+ = From within dashboard (recommended) =
89
+
90
+ 1. Navigate to `Dashboard` ▸ `Plugins` ▸ `Add New`;
91
+ 2. Search for `Shortcodes Ultimate`;
92
+ 3. Click `Install`, then `Activate`.
93
 
94
+ [Watch video of the process](https://www.youtube.com/watch?v=6xhplrZJD9c).
 
95
 
96
+ = Manual installation =
97
 
98
+ 1. Download a .zip file with plugin;
99
+ 2. Unzip downloaded archive and upload `shortcodes-ultimate` folder under your `/wp-content/plugins/` directory (resulted plugin path should be `/wp-content/plugins/shortcodes-ultimate/**`);
100
+ 1. Navigate to `Dashboard` ▸ `Plugins` and active the plugin.
101
+
102
+ [Detailed installation guide](http://docs.getshortcodes.com/article/13-plugin-installation).
103
 
104
 
105
  == Screenshots ==
149
 
150
  == Changelog ==
151
 
152
+ = trunk =
153
+
154
+ **Fixes**
155
+
156
+ - Fixed `<img>` icon appearance of the `[su_service]` shortcode
157
+
158
+
159
+ = 5.0.8 =
160
+
161
+ **Fixes**
162
+
163
+ - Fixed Live Preview, wasn't representing changed settings
164
+ - Fixed `[su_siblings]`, now it works again at top-level pages
165
+
166
+ **Other**
167
+
168
+ - Various code improvements
169
+ - New filters for gallery, slider, and carousel
170
+ - Returned `su_cmpt()` and `su_compatibility_mode_prefix()` utils
171
+
172
+
173
  = 5.0.7 =
174
 
175
  **Security update**
shortcodes-ultimate.php CHANGED
@@ -2,7 +2,7 @@
2
  /**
3
  * Plugin Name: Shortcodes Ultimate
4
  * Plugin URI: https://getshortcodes.com/
5
- * Version: 5.0.7
6
  * Author: Vladimir Anokhin
7
  * Author URI: https://vanokhin.com/
8
  * Description: A comprehensive collection of visual components for WordPress
@@ -15,7 +15,7 @@
15
  * Define plugin constants.
16
  */
17
  define( 'SU_PLUGIN_FILE', __FILE__ );
18
- define( 'SU_PLUGIN_VERSION', '5.0.7' );
19
 
20
  /**
21
  * Load dependencies.
@@ -50,7 +50,7 @@ function run_shortcodes_ultimate() {
50
 
51
  require_once plugin_dir_path( __FILE__ ) . 'includes/class-shortcodes-ultimate.php';
52
 
53
- $plugin = new Shortcodes_Ultimate( __FILE__, SU_PLUGIN_VERSION );
54
 
55
  do_action( 'su/ready' );
56
 
2
  /**
3
  * Plugin Name: Shortcodes Ultimate
4
  * Plugin URI: https://getshortcodes.com/
5
+ * Version: 5.0.8
6
  * Author: Vladimir Anokhin
7
  * Author URI: https://vanokhin.com/
8
  * Description: A comprehensive collection of visual components for WordPress
15
  * Define plugin constants.
16
  */
17
  define( 'SU_PLUGIN_FILE', __FILE__ );
18
+ define( 'SU_PLUGIN_VERSION', '5.0.8' );
19
 
20
  /**
21
  * Load dependencies.
50
 
51
  require_once plugin_dir_path( __FILE__ ) . 'includes/class-shortcodes-ultimate.php';
52
 
53
+ $plugin = new Shortcodes_Ultimate( __FILE__, SU_PLUGIN_VERSION, 'shortcodes-ultimate-' );
54
 
55
  do_action( 'su/ready' );
56