To work the plugin the necessary files you must place the files listed below on your server
After this you need to connect these files inside the tag "head" of your site
Typically, style files placed in the folder "css", and script files - in a folder "js", but your folder structure may be another.
If you have an another directory structure, make sure you set the correct path to the files.
Once you have written the connection of necessary files, plugin needs to be initialized.
For this purpose, in tag "head" need to add this code below the code of connection.
Option initialize all parameters
For create the code of the menu, you can simply take the most standard and the most spread multi-level menu structure.
For its main parent element you need set the class, wich you assigned in initialization, to plugin to know which menu needed to convert.
- What is the Envato Market API?
The Envato Market sites have an API so that ...
- How do I use the API?
If you're a developer and would like ...
- What is an API key?
Your API key is a password for applications to ...
- Phones & Telecommunications
- Mobile Phones (346696)
- Mobile Phones (346696)
- Phone Bags & Cases (14122765)
- Backup Powers (147439)
- Phone Bags & Cases (14122765)
- Backup Powers (147439)
- Function
- Waterproof (69740)
- Dirt-resistant (11721669)
- Power Case (41850)
- Water/Dirt/Shock Proof (42836)
Option | Default value | Datatype | Description |
---|---|---|---|
currentClass | 'cur' | String | Class for the selected menu item It may take the values: any Latin characters |
markerClass | 'harMark' | String | Class for the marker elements It may take the values: any Latin characters |
onlyOne | true | bolean | true - open can be only one item, false - the number of open items is not limited to It may take the values: true or false |
speed | 300 | number | Animation speed It may take the values: any positive number |
clicablelink | false | bolean | It enables or disables the clickable links that have attachments It may take the values: true or false |
event | 'click' | string | The event that accordion headers will react to in order to activate the associated panel. It may take the values: any mouse event |
colortheme | 'Pink' | string | Specifies a preset color theme It may take the values: "BlueGrey", "Red", "Pink", "Purple", "DeepPurple", "Indigo", "Blue", "LightBlue", "Cyan", "Teal", "Green", "LightGreen", "Lime", "Yellow", "Amber", "Orange", "DeepOrange", "Brown", "Grey", "LightGray", "UltraGray", "Black" This option can be set using the attribute "data-colortheme" <ul class="ini_class" data-colortheme="Pink"> [YOUR LIST] </ul> |
layout | 'menu' | string | Sets the basic design of the blocks It may take the values: "menu", "content", "filter" This option can be set using the attribute "data-layout" <ul class="ini_class" data-layout="menu"> [YOUR LIST] </ul> |
markershape | 'square' | string | Specifies the shape of the parent marker It may take the values: "square", "round", "none" This option can be set using the attribute "data-markershape" <ul class="ini_class" data-markershape="square"> [YOUR LIST] </ul> |
markersign | 'pm' | string | Specifies the shape of the sign marker It may take the values: "pm", "arrow", "triangle" This option can be set using the attribute "data-markersign" <ul class="ini_class" data-markersign="pm"> [YOUR LIST] </ul> |
markerpos | 'right' | string | Specifies position of the marker It may take the values: "right", "left" This option can be set using the attribute "data-markerpos" <ul class="ini_class" data-markerpos="right"> [YOUR LIST] </ul> |
colortype | 'bg' | string | Specifies that will be painted, background or text It may take the values: "bg", "text" This option can be set using the attribute "data-colortype" <ul class="ini_class" data-colortype="bg"> [YOUR LIST] </ul> |
destroy() |
Removes all the functionality of menu. It returns the item in the condition before the initialization of the plug-in $('.your_class').liAccordion('destroy'); |
disable() |
Blocking of plugin work $('.your_class').liAccordion('disable'); |
enable() |
Unblocking of plugin work $('.your_class').liAccordion('enable'); |
collapseall() |
Collapsing all panels $('.your_class').liAccordion('collapseall'); |
expandall() |
Expanding all panels $('.your_class').liAccordion('expandall'); |
create() |
Triggered when the liAccordion is created
$('.ini_class').liAccordion({ |
beforeOpen() |
Triggered before open liAccordion Panel.
$('.ini_class').liAccordion({ |
afterOpen() |
Triggered after open liAccordion Panel.
$('.ini_class').liAccordion({ |
beforeClose() |
Triggered before close liAccordion Panel
$('.ini_class').liAccordion({ |
afterClose() |
Triggered after close liAccordion Panel
$('.ini_class').liAccordion({ |
To main parent element of plugin you must assign three attributes, which are responsible for displaying the marker:
1. Marker Shape:
data-markershape="square"
- "square" (default)
- "round"
- "none"
2. Marker Sign:
data-markersign="pm"
- "pm" (default)
- "arrow"
- "triangle"
2. Marker Position:
data-markerpos="right"
- "right" (default)
- "left"
example:
<ul class="ini_class" data-colortheme="Pink" data-layout="menu" data-markershape="square" data-markersign="triangle" data-markerpos="left" data-colortype="bg"> [YOUR LIST] </ul>
marker-pos-right |
marker-pos-left |
|||||
marker-sign-pm |
marker-sign-arrow |
marker-sign-triangle |
marker-sign-pm |
marker-sign-arrow |
marker-sign-triangle |
|
data-markershape="square" |
Panel Title | Panel Title | Panel Title | Panel Title | Panel Title | Panel Title |
data-markershape="round" |
Panel Title | Panel Title | Panel Title | Panel Title | Panel Title | Panel Title |
data-markershape="none" |
Panel Title | Panel Title | Panel Title | Panel Title | Panel Title | Panel Title |
In the style of plugin provides three basic types of structure.
By manipulating the attribute "data-layout", you will be able to use this plug-in for all your needs
data-layout="menu"
- "menu" (default)
- "content"
- "filter"
example:
<ul class="ini_class" data-colortheme="Pink" data-layout="menu" data-markershape="square" data-markersign="triangle" data-markerpos="left" data-colortype="bg"> [YOUR LIST] </ul>
These color values are already present in the file liAccordion.css
attribute "data-colortype" specifies that will be painted, background or text
data-colortype="bg"
- "bg" (default)
- "text"
example:
<ul class="ini_class" data-colortheme="Pink" data-layout="menu" data-markershape="square" data-markersign="triangle" data-markerpos="left" data-colortype="bg"> [YOUR LIST] </ul>
BlueGrey | |
Red | |
Pink | |
Purple | |
DeepPurple | |
Indigo | |
Blue | |
LightBlue | |
Cyan | |
Teal | |
Green | |
LightGreen | |
Lime | |
Yellow | |
Amber | |
Orange | |
DeepOrange | |
Brown | |
Grey | |
LightGray | |
UltraGray | |
Black |