Friday, January 27, 2017

Sourcehunt 17.1: 7 Interesting PHP Packages to Keep an Eye On

If you're new to Sourcehunt, it's our monthly post for promoting open source projects that seem interesting or promising and could use help in terms of Github stars or pull requests. It's our way of giving back - promoting projects that we use (or could use) so that they gain enough exposure to attract a wider audience, a powerful community and, possibly, new contributors or sponsors.

Without further ado, let's dive into this month's offering.

Sourcehunt logo

---

### [dannyvankooten/vat.php](http://ift.tt/2jRnJRs) [162 ★]

As per their documentation:

> vat.php is a simple PHP library which helps you to deal with European VAT rules. It helps you...

> - Grab up-to-date VAT rates for any European member state
> - Validate VAT numbers (by format or existence)
> - Work with ISO 3166-1 alpha-2 country codes and determine whether they're part of the EU.
> - Geolocate IP addresses
> - The library uses jsonvat.com to obtain its data for the VAT rates.

The library is little more than an API proxy to jsonvat.com, with added utility functions. However, those utility functions and the ease of use of this lib make it a valuable addition to any e-commerce site's [vendor](http://ift.tt/2dmqkVr) directory. It even supports checking general country data, like so:

```php
$countries = new DvK\Vat\Countries();
$countries->all(); // array of country codes + names
$countries->name('NL') // Netherlands
$countries->europe(); // array of EU country codes + names
$countries->inEurope('NL'); // true
$countries->ip('8.8.8.8'); // US
```

---

### [Microsoft/tolerant-php-parser](http://ift.tt/2k51MlN) [210 ★]

Microsoft? Do they really need promotion/help? Well, due to the nature of the package and its implied usefulness, I vote yes.

Continue reading %Sourcehunt 17.1: 7 Interesting PHP Packages to Keep an Eye On%


by Bruno Skvorc via SitePoint

No comments:

Post a Comment