Download the PHP package anetwork/sidenav without Composer
On this page you can find all versions of the php package anetwork/sidenav. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package sidenav
Anetwork SideNav
SideNav is a PHP package which helps you generate powerful sidebar navigation.
Features
- SubMenu : Define your submenu to item
- Grouping : Define your items in groups
- Cheking : Define dynamic menues and submenues with if statement support
Introduction
- A php component that makes it easier to build vertical nav menus
- The sidenav package can manage your sidebar navigations items on your project
- you can install this package with composer and config your sidebar navigations items
Requirement
- php 5.5 >=
- HHVM
Install with composer
You can install this package throw the Composer by running:
Register a new item
- you should use the register method of sidenav object
- the method wants 2 arguments
- the first one should be a string of your item name
- the second one must be a function literal to use Menu Object for define all of menu options
Register submenu with Check Status
If you want register a submenu in item with checkStatus, you should use subWithCheck method of Menu Object
- the method , accepts 3 arguments
- first one must be a string of your item name
- second one must be function literal to use Menu Object for define all of menu options
- third one must be a function literal of your check state , return of function must be true or false
Register With Check Status
If you want register a item with checkStatus, you should use registerWithCheck method of SideNav Object
- the method , accepts 3 arguments
- first one must be a string of your item name
- second one must be function literal to use Menu Object for define all of menu options
- third one must be a function literal of your check state , return of function mustb be true or false
Group
- You can make a group menu with SideNav::group method
Render
-
You can use the render method of SideNav object to return your menu array
- if you want to render your group , just call your group name in argument
Menu options
Method | status | Parameter | Type of parameter |
---|---|---|---|
->icon() |
required | Define icon class | String |
->link() |
required | Set link of item | String |
->regex() |
optional | Set the regex of item link | array |
->className() |
optional | The class of item | String |
->newTab() |
optional | newTab link target | Boolean : defalt => false |
->title() |
required | The title of item | String |
->isNew() |
optional | Define the item is new | Boolean : default => false |
->selected() |
optional | item selected status | Boolean : default => false |
->openChildOnClick() |
optional | the sub menu status | Boolean : default => true |
All versions of sidenav with dependencies
PHP Build Version
Package Version
Requires
php Version
>=5.5
The package anetwork/sidenav contains the following files
Loading the files please wait ....