Tabby Responsive Tabs - Version 1.3.5

Version Description

Download this release

Release Info

Developer numeeja
Plugin Icon 128x128 Tabby Responsive Tabs
Version 1.3.5
Comparing to
See all releases

Code changes from version 1.3.4 to 1.3.5

Files changed (3) hide show
  1. includes/admin.php +1 -1
  2. readme.txt +1 -1
  3. tabby-responsive-tabs.php +14 -14
includes/admin.php CHANGED
@@ -19,7 +19,7 @@ if ( ! defined( 'ABSPATH' ) ) exit;
19
  *
20
  */
21
  function cc_tabby_rt_admin_css() {
22
- wp_register_style( 'cc-tabby-admin-css', CC_TABBY_PLUGIN_URL . 'css/admin.css', '', '1.3.0' );
23
  wp_enqueue_style( 'cc-tabby-admin-css' );
24
  }
25
  add_action( 'admin_enqueue_scripts', 'cc_tabby_rt_admin_css' );
19
  *
20
  */
21
  function cc_tabby_rt_admin_css() {
22
+ wp_register_style( 'cc-tabby-admin-css', CC_TABBY_PLUGIN_URL . 'css/admin.css', '', CC_TABBY_PLUGIN_VERSION );
23
  wp_enqueue_style( 'cc-tabby-admin-css' );
24
  }
25
  add_action( 'admin_enqueue_scripts', 'cc_tabby_rt_admin_css' );
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: numeeja
3
  Donate link: https://cubecolour.co.uk/wp
4
  Tags: tabs, tab, responsive, accordion, shortcode
5
  Tested up to: 5.9
6
- Stable tag: 1.3.4
7
  License: GPLv2
8
  License URI: https://www.gnu.org/licenses/gpl-2.0.html
9
  License of javascript:
3
  Donate link: https://cubecolour.co.uk/wp
4
  Tags: tabs, tab, responsive, accordion, shortcode
5
  Tested up to: 5.9
6
+ Stable tag: 1.3.5
7
  License: GPLv2
8
  License URI: https://www.gnu.org/licenses/gpl-2.0.html
9
  License of javascript:
tabby-responsive-tabs.php CHANGED
@@ -4,8 +4,8 @@ Plugin Name: Tabby Responsive Tabs
4
  Plugin URI: https://cubecolour.co.uk/tabby-responsive-tabs
5
  Description: Create responsive tabs inside your posts, pages or custom post types by adding simple shortcodes. An easy to use admin page can be added to customise the tab styles with the optional Tabby Responsive Tabs Customiser add-on plugin.
6
  Author: cubecolour
7
- Version: 1.3.4
8
- Requires at least: 5.0
9
  Requires PHP: 5.6
10
  Author URI: https://cubecolour.co.uk
11
 
@@ -63,7 +63,7 @@ if ( ! defined( 'ABSPATH' ) ) exit;
63
  */
64
  define( 'CC_TABBY_PLUGIN_URL', plugin_dir_url( __FILE__ ) );
65
  define( 'CC_TABBY_PLUGIN_PATH', plugin_dir_path( __FILE__ ) );
66
- define( 'CC_TABBY_PLUGIN_VERSION', '1.3.4' );
67
 
68
  function cc_tabby_plugin_version(){
69
  return CC_TABBY_PLUGIN_VERSION;
@@ -117,18 +117,15 @@ if ( !function_exists( 'cc_remove_tabby_default_css' ) ) {
117
 
118
  /**
119
  * Register & enqueue the stylesheet
120
- * To use custom styles, copy the content of the tabby.css to your child theme (or additional css in the WordPress customizer) and edit the styles there.
121
- * When using custom styles, it is important to prevent the default styles from loading by deselecting the "Include default tab by stylesheet" checkbox in the tabby settings page at settings/tabby
122
-
123
- * Alternatively, for a 'no code' solution, use the tabby responsive tabs customiser plugin
124
  * available from from https:cubecolour.co.uk/tabby-responsive-tabs-customiser
125
  *
126
  */
127
 
128
- /**
129
- * Register script & styles
130
- *
131
- */
132
  function cc_tabby_register_cssjs() {
133
  wp_register_style( 'tabby', CC_TABBY_PLUGIN_URL . 'css/tabby.css', '', CC_TABBY_PLUGIN_VERSION );
134
  wp_register_style( 'tabby-print', CC_TABBY_PLUGIN_URL . 'css/tabby-print.css', '', CC_TABBY_PLUGIN_VERSION, 'print' );
@@ -140,6 +137,7 @@ function cc_tabby_register_cssjs() {
140
  }
141
  add_action( 'wp_enqueue_scripts', 'cc_tabby_register_cssjs' );
142
 
 
143
  /**
144
  * Sanitize html element
145
  *
@@ -155,6 +153,7 @@ function cc_sanitize_html_element( $element ){
155
  }
156
  }
157
 
 
158
  /**
159
  * SHORTCODE FOR TABBY
160
  * use [tabby]
@@ -180,6 +179,7 @@ function cc_shortcode_tabby( $atts, $content = null ) {
180
  'required' => FALSE,
181
  ), $atts );
182
 
 
183
  $tabtarget = sanitize_title_with_dashes( remove_accents( wp_kses_decode_entities( $args['title'] ) ) );
184
  $tab_title_element = cc_sanitize_html_element( get_option( 'cc_tabby_tab_title_element', 'h2' ) );
185
 
@@ -219,12 +219,12 @@ function cc_shortcode_tabby( $atts, $content = null ) {
219
  $firsttab = FALSE;
220
 
221
  //* Build output if we are making the first tab
222
- return '<div class="responsive-tabs">' . "\n" . '<' . $tab_title_element . ' class="tabtitle">' . $addtabicon . wp_kses( $args['title'], array( 'br' => array(), 'strong' => array(), 'em' => array() ) ) . '</' . $tab_title_element . '>' . "\n" . '<div class="' . sanitize_html_class( $tabcontentclass ) . '">' . "\n";
223
  }
224
 
225
  else {
226
  //* Build output if we are making a non-first tab
227
- return "\n" . '</div><' . $tab_title_element . ' class="tabtitle">' . $addtabicon . wp_kses( $args['title'], array( 'br' => array(), 'strong' => array(), 'em' => array() ) ) . '</' . $tab_title_element . '>' . "\n" . '<div class="' . sanitize_html_class( $tabcontentclass ) . '">' . "\n";
228
  }
229
  }
230
  add_shortcode( 'tabby', 'cc_shortcode_tabby' );
@@ -237,7 +237,7 @@ add_shortcode( 'tabby', 'cc_shortcode_tabby' );
237
  */
238
  function cc_shortcode_tabbyending( $atts, $content = null ) {
239
 
240
- //* add screen styles, but only if the tabby responsive tabs customiser or a custom tabby styles plugin is not active
241
  if ( ( !function_exists( 'cc_remove_tabby_default_css' ) ) && ( !function_exists( 'cc_remove_tabby_default_style' ) ) && ( 1 == get_option( 'cc_tabby_default_styles' ) ) ) {
242
  wp_enqueue_style( 'tabby' );
243
  }
4
  Plugin URI: https://cubecolour.co.uk/tabby-responsive-tabs
5
  Description: Create responsive tabs inside your posts, pages or custom post types by adding simple shortcodes. An easy to use admin page can be added to customise the tab styles with the optional Tabby Responsive Tabs Customiser add-on plugin.
6
  Author: cubecolour
7
+ Version: 1.3.5
8
+ Requires at least: 4.9
9
  Requires PHP: 5.6
10
  Author URI: https://cubecolour.co.uk
11
 
63
  */
64
  define( 'CC_TABBY_PLUGIN_URL', plugin_dir_url( __FILE__ ) );
65
  define( 'CC_TABBY_PLUGIN_PATH', plugin_dir_path( __FILE__ ) );
66
+ define( 'CC_TABBY_PLUGIN_VERSION', '1.3.5' );
67
 
68
  function cc_tabby_plugin_version(){
69
  return CC_TABBY_PLUGIN_VERSION;
117
 
118
  /**
119
  * Register & enqueue the stylesheet
120
+ * If you want to use custom styles, copy the content of the tabby.css to your child theme and edit the styles there
121
+ * Prevent the default styles from loading by deselecting the "Include default tab by stylesheet" checkbox in the tabby settings page at settings/tabby
122
+ * Alternatively use the tabby responsive tabs customiser plugin
 
123
  * available from from https:cubecolour.co.uk/tabby-responsive-tabs-customiser
124
  *
125
  */
126
 
127
+
128
+ //* Register script & styles
 
 
129
  function cc_tabby_register_cssjs() {
130
  wp_register_style( 'tabby', CC_TABBY_PLUGIN_URL . 'css/tabby.css', '', CC_TABBY_PLUGIN_VERSION );
131
  wp_register_style( 'tabby-print', CC_TABBY_PLUGIN_URL . 'css/tabby-print.css', '', CC_TABBY_PLUGIN_VERSION, 'print' );
137
  }
138
  add_action( 'wp_enqueue_scripts', 'cc_tabby_register_cssjs' );
139
 
140
+
141
  /**
142
  * Sanitize html element
143
  *
153
  }
154
  }
155
 
156
+
157
  /**
158
  * SHORTCODE FOR TABBY
159
  * use [tabby]
179
  'required' => FALSE,
180
  ), $atts );
181
 
182
+
183
  $tabtarget = sanitize_title_with_dashes( remove_accents( wp_kses_decode_entities( $args['title'] ) ) );
184
  $tab_title_element = cc_sanitize_html_element( get_option( 'cc_tabby_tab_title_element', 'h2' ) );
185
 
219
  $firsttab = FALSE;
220
 
221
  //* Build output if we are making the first tab
222
+ return '<div class="responsive-tabs">' . "\n" . '<' . $tab_title_element . ' class="tabtitle">' . $addtabicon . wp_kses( $args['title'], array( 'br' => array(), 'strong' => array(), 'em' => array() ) ) . '</' . $tab_title_element . '>' . "\n" . '<div class="' . sanitize_text_field( $tabcontentclass ) . '">' . "\n";
223
  }
224
 
225
  else {
226
  //* Build output if we are making a non-first tab
227
+ return "\n" . '</div><' . $tab_title_element . ' class="tabtitle">' . $addtabicon . wp_kses( $args['title'], array( 'br' => array(), 'strong' => array(), 'em' => array() ) ) . '</' . $tab_title_element . '>' . "\n" . '<div class="' . sanitize_text_field( $tabcontentclass ) . '">' . "\n";
228
  }
229
  }
230
  add_shortcode( 'tabby', 'cc_shortcode_tabby' );
237
  */
238
  function cc_shortcode_tabbyending( $atts, $content = null ) {
239
 
240
+ //* add screen styles, but only if the customiser or a custom styles plugin is not active
241
  if ( ( !function_exists( 'cc_remove_tabby_default_css' ) ) && ( !function_exists( 'cc_remove_tabby_default_style' ) ) && ( 1 == get_option( 'cc_tabby_default_styles' ) ) ) {
242
  wp_enqueue_style( 'tabby' );
243
  }