Skip to content

Commit a035b48

Browse files
committed
readme updates
1 parent 955c601 commit a035b48

File tree

1 file changed

+13
-5
lines changed

1 file changed

+13
-5
lines changed

README.md

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# sg-nric
1+
# sg-nric: PHP Singapore NRIC/FIN validator
22

33
PHP Singapore NRIC (National Registration Identity Card) or FIN (Foreign Identification Number) validator package
44

@@ -17,14 +17,22 @@ composer require makowskid/sg-nric
1717
## Usage
1818

1919
```bash
20-
$validator = new \Makowskid\SgNric\SgNric();
2120

22-
if($validator->isNricValid($theNric)) ..
21+
use Makowskid\SgNric\SgNric;
2322

24-
//or
23+
$validator = new SgNric();
2524

26-
if($validatator->isFinValid($theNric)) ..
25+
if ($validator->isNricValid($theNric)) {
26+
// NRIC is valid
27+
// Your code here...
28+
}
2729

30+
// OR
31+
32+
if ($validator->isFinValid($theFin)) {
33+
// FIN is valid
34+
// Your code here...
35+
}
2836

2937
```
3038

0 commit comments

Comments
 (0)