Skip to content
This repository has been archived by the owner on Sep 28, 2021. It is now read-only.

Commit

Permalink
Add documentation for string parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
gerardojbaez committed Aug 3, 2016
1 parent b8db096 commit dd15c17
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ moneyFormat(12.99, 'USD'); // RESULT: $12.99
- [Currencies Supported](#currencies-supported)
- [Formatting Using Helper Function](#formatting-using-helper-function)
- [Formatting Using Class](#formatting-using-class)
- [Parse String](#parse-string)
- [Get Currency Information](#get-currency-information)
- [Get All Supported Currencies](#get-all-supported-currencies)
- [License](#license)
Expand Down Expand Up @@ -83,6 +84,14 @@ echo $money; // The same as using $money->format()
echo $money->amount(); // RESULT: 10,00,000
```

### Parse String

```php
<?php

echo Money::parse('$1,200.90', 'USD')->toDecimal(); // RESULT: 1200.9
```

### Get Currency Information

```php
Expand Down

0 comments on commit dd15c17

Please sign in to comment.