Skip to content

Commit 2a473de

Browse files
committed
update README.md
1 parent ed1e764 commit 2a473de

1 file changed

Lines changed: 25 additions & 0 deletions

File tree

README.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,27 @@
11
# cakephp3-ip-filter
22
restrict access by ip address for CakePHP3 Component
3+
4+
## Installation
5+
6+
You can install this plugin into your CakePHP application using [composer](http://getcomposer.org).
7+
8+
The recommended way to install composer packages is:
9+
10+
```
11+
composer require tyrellsys/cakephp3-ip-filter
12+
```
13+
14+
## Configuration
15+
16+
Controller::initialize
17+
```
18+
...
19+
public function initialize($event)
20+
{
21+
....
22+
$this->loadComponent('Tyrellsys/CakePHP3IpFilter.IpFilter', [
23+
'trustProxy' => true,
24+
'whitelist' => '192.168.0.0/24' // array OR comma separate value
25+
]);
26+
...
27+
```

0 commit comments

Comments
 (0)