PHPackages                             scholte/uri - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. scholte/uri

ActiveLibrary

scholte/uri
===========

RFC 3986 PHP URI extension

1.1.2(6y ago)028PHPPHP &gt;=7.1CI failing

Since Jul 9Pushed 6y ago1 watchersCompare

[ Source](https://github.com/scholte/uri)[ Packagist](https://packagist.org/packages/scholte/uri)[ RSS](/packages/scholte-uri/feed)WikiDiscussions master Synced 3d ago

READMEChangelogDependencies (5)Versions (6)Used By (0)

README
======

[](#readme)

This object follows the PSR-7 HTTP message described at [http://www.php-fig.org/psr/psr-7/](http://www.php-fig.org/psr/psr-7/.) and [RFC 3986](https://tools.ietf.org/html/rfc3986). Every URI has a specific construction as shown below:

```
tel:+31-123-456-789
urn:oasis:names:specification:docbook:dtd:xml:4.1.2
ftp://ftp.is.co.za/rfc/rfc1808.txt
mailto:John.Doe@example.com
scheme:[//[user:password@]host[:port]][/]path[?query][#fragment]

```

1. Protocol: `scheme`
2. Authentication: `user:password`
3. Domain: `www.host.com`
4. Port: `80`
5. Path: `/path`
6. Query: `?parameter=value`
7. Fragment: `#fragment`

Installation
------------

[](#installation)

This package can be installed using composer:

```
$ composer require scholte/uri
```

How to use
----------

[](#how-to-use)

The URI object can be used for all RFC 3986 URI's. It is possible to change or extract specific parts of the URI without having to search and replace those parts.

```
