Lets you add tabs to your post and pages using a shortcode.
To add tabs to you post or pages just add this shortcode:
[tabs] [tab title="title1"] tab content tab content [/tab] [tab title="title2"] another content tab [/tab] [/tabs]
Here are the some attributes that the shortcode also excepts
// default attributes
[tabs collapsible=true selected='0' event='click' position='top' ]
[tab title="title1"] tab content [/tab] [tab title="title2"] another content tab [/tab] [/tabs]
- collapsible = true or false - weather the tabs should be allowed to be collapsed - this doesn't work with twitter bootstrap
- selected = integer for example - what tab should be selected. 0 means the first tab. 1 means the second tab etc.
- event = 'click' or 'mouseover' - does do you user need to click on the tab or just mouse over to get to the content. Tip: Don't use mouseover if you are concerned with mobile.
- position = 'top' , 'bottom' , 'left', 'right' on what side do you want the tabs to appear. See screenshots for an example.
- vertical_tabs = true or false - depreciated is the same as position = left
=How to get rid of unwanted
Get rid of unneeded white space inside your shortcode
=My theme already has styling for tabs how can I remove the default styling=
Easy. Add the line
add_theme_support( 'tabs', 'style-only' ); to you functions.php file. Preferably somewhere in a function that is being called by the after theme setup action
=I am using the twitter bootstrap framework how do I make sure that the tabs work with it.= The shortcode support the twitter bootstrap framework. add_theme_support( 'tabs', 'twitter-bootstrap' );
How can I contribute to this plugin
If you must ask. Checkout the source code at https://github.com/ubc/tabs-shortcode
Feel free to submit pull requests.
- Minified files so that things are load even faster, saving tree though bandwidth.
- Bug fixes: Removes notices
- updated to styles better with version jQuery 1.9
- Rewrite of the plugin
- Now we are adding some tab styling by default
- Added position attribute (top, bottom, left, right)
- removing unwanted warnings.
- bug fixes now it plays more nicely with other short codes.
- Initial Release