Toggle Show/Hide
Developed by azurecurve
Plugin Description
Toggle shortcode can be used to show/hide content.
[toggle style=1]content[/toggle]
to use toggle in basic format; parameters are read from settings.
Two toggle styles are supported:
-
Style 1
is the traditional toggle show/hide. -
Style 2
is a read more toggle.
Apply a parameter of style=1/2
to select the the type of toggle (e.g. [toggle style=2]content[/toggle]
); a default parameter can be set so a style only needs to be defined if the othe style toggle is required.
The following parameters can be used for the standard toggle:
-
title
– default title text of the toggle. -
expand
– set to 1 to display toggle open; 0 to display toggle closed. e.g.[toggle expand=1]content[/toggle]
-
width
– override width from settings. e.g.[toggle width=75%]content[/toggle]
-
border
– override border from settings. e.g.[toggle border='none']content[/toggle] or
[toggle border=’1px dashed #FF0000′]content[/toggle]` -
title_color
– override title color from settings. e.g.[toggle title_color='#000']content[/toggle]
-
title_font
– override title font family from settings. e.g.[toggle title_font='Arial, Calibri']content[/toggle]
-
title_font_size
– override title font size from settings. e.g.[toggle title_font_size='14px']content[/toggle]
-
title_font_weight
– override title font weight from settings. e.g.[toggle title_font_weight=600]content[/toggle]
-
bgtitle
– override text background colour from settings. e.g.[toggle bgtitle='#007FFF']content[/toggle]
-
text_color
– override text colour from settings. e.g.[toggle bgtext='#000']content[/toggle]
-
text_font
– override text font family from settings. e.g.[toggle text_font='Arial, Calibri']content[/toggle]
-
text_font_size
– override text font size from settings. e.g.[toggle text_font_size='14px']content[/toggle]
-
text_font_weight
– override text font weight from settings. e.g.[toggle text_font_weight=600]content[/toggle]
-
bgtext
– override text background colour from settings. e.g.[toggle bgtext='#000']content[/toggle]
-
disable_image
– set to 1 to disable toggle image. e.g.[toggle disable_image=1]content[/toggle]
-
image_location
– set to left or right to override default. e.g.[toggle image_location='right']content[/toggle]
Select toggle image in options or network options; allows different sites in a network to use different images.
Shortcodes can now be used inside the content or title of the toggle if the relevant option is set.
When using a read more toggle, apply the <!--readmore-->
tag where the readmore button should be placed. e.g. [toggle style=2]content<!--readmore-->content[/toggle]
This plugin is multisite compatible; each site can be set to use network settings or locally defined ones.
- Download the latest release of the plugin from GitHub.
- Upload the entire zip file using the Plugins upload function in your ClassicPress admin panel.
- Activate the plugin.
- Configure relevant settings via the configuration page in the admin control panel (azurecurve menu).
Yes, the .pot file is in the plugins languages folder; if you do translate this plugin, please sent the .po and .mo files to [email protected] for inclusion in the next version (full credit will be given).
This plugin is developed for ClassicPress, but will likely work on WordPress.
- Update plugin header for compatibility with ClasssicPress v2.
- Update plugin header and readme for compatibility with ClassicPress Directory v2.
- Update Update Manager to version 2.5.0.
- Update readme file for compatibility with ClassicPress Directory.
- Update readme files.
- Update language template.
- Fix bug with azurecurve menu.
- Update azurecurve menu.
- Update readme files.
- Tidy up some code on settings page.
- Remove jQuery UI tabs and add tabs using aria.
- Update translations to escape strings.
- Refactor settings page to be accessible using jQuery UI Tabs.
- Fix bug with read more toggle when no read more tag specified.
- Compress banners and icons.
- Add Read More toggle as second style.
- Add option to select default toggle style.
- Refactor settings page.
- Fix bug with missing text_font and text_font_size default options.
- Update azurecurve menu.
- Undo amendment of loading css and javascript only if shortcodes on the page as this causes issues as toggle is integrated into other plugins which use the shortcode within a shortcode.
- Fix plugin action link to use admin_url() function.
- Rewrite option handling so defaults not stored in database on plugin initialisation.
- Add plugin icon and banner.
- Update azurecurve plugin menu.
- Amend to only load css when shortcode on page.
- Fix bug with unassigned $background_title variable.
- Fix bug with setting of default options.
- Fix bug with plugin menu.
- Update plugin menu css.
- Fix bug with default title not being set correctly.
- Rewrite default option creation function to resolve several bugs.
- Upgrade azurecurve plugin to store available plugins in options.
- Update Update Manager class to v2.0.0.
- Update action link.
- Update azurecurve menu icon with compressed image.
- Fix bug with incorrect language load text domain.
- Add integration with Update Manager for automatic updates.
- Fix issue with display of azurecurve menu.
- Change settings page heading.
- Add load_plugin_textdomain to handle translations.
- Update azurecurve menu for easier maintenance.
- Move require of azurecurve menu below security check.
- Localization fixes and translation into Russian (contributed by @Norskes).
- Initial release for ClassicPress forked from azurecurve Toggle Show/Hide WordPress Plugin.