Skip to content

EGYG33K/DomainParserBundle

Repository files navigation

domain-parser-bundle

Software License Build Status Total Downloads Latest Stable Version

Integration of Domain Parser into Symfony

System Requirements

You need PHP >= 5.5.0 but the latest stable version of PHP/HHVM is recommended.

Install

Via Composer

$ composer require egyg33k/domain-parser-bundle

Usage

        // Add this line to your AppKernel.php new Egyg33k\DomainParserBundle\Egyg33kDomainParserBundle(),
        // Then you can use it as following
        $parser = $this->container->get('egyg33k.domainParser');
        $host = 'http://user:[email protected]:8080/path/to/page.html?query=string#fragment';
        $url = $parser->parseUrl($host);
        var_dump($url);

Documentation

Original docs https://github.com/jeremykendall/php-domain-parser

Testing

$ phpunit

Security

If you discover any security related issues, please email [email protected] instead of using the issue tracker.

Credits

License

The MIT License (MIT). Please see License File for more information.