Examples
Trigger Text
To assign target content for the expand element, wrapping the content within the shortcode tags like so:
Swaptitle Attribute
The swaptitle attribute is used to ‘swap’ or replace the title while in the expanded state.
Examples
On
Use the trigpos attribute change the position of the trigger above or below the target. Default trigpos value is above.
above (default) – the trigger text is placed above the collapsed content
below – will move the trigger text below the target content
Example
Setting the ID attribute will assign the expand element a HTML ID attribute with the provided value. Do not use duplicate ID values on elements that will exist on the same page. If no ID attribute is defined, the ID will be automatically assigned a unique, random value.
Example
Pocket Calculator
When an ID attribute is defined, the value can be used as an URL anchor to automatically expand and scroll to the target content on page load (demo).
Expanded Attribute
Setting the expanded attribute to true will set the default position of the element to open (expanded). The default position is closed (collapsed).
Example
Vader
The tag attribute replaces the default HTML tag that wraps the trigger text. The HTML tag is set globally in the plugin options, under Tag.
Example
A Long Time Ago
The targtag attribute replaces the default HTML tag that wraps the target content. By default the HTML tag is div.
Example
A Long Time AgoTarget Content
Alt Attribute
The alt attribute is used to provide additional information on non-textual screen elements that is used by screen readers and robots. In modern browsers alt text no longer “pops up” on roll-over, the title attribute is now used for this.
Example
Imperial Starfleet
The notitle attribute is used to prevent any hover-over text from being displayed.
Example
Cloud City