Skip to content

Commit

Permalink
Update instruction and readme files
Browse files Browse the repository at this point in the history
  • Loading branch information
nyamsprod committed Aug 3, 2023
1 parent 0f40cc9 commit 2ae362e
Showing 1 changed file with 0 additions and 45 deletions.
45 changes: 0 additions & 45 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
URI
=======

[![Build](https://github.com/thephpleague/uri/workflows/build/badge.svg)](https://github.com/thephpleague/uri/actions?query=workflow%3A%22build%22)
[![Software License](https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square)](LICENSE)
[![Latest Version](https://img.shields.io/github/release/thephpleague/uri.svg?style=flat-square)](https://github.com/thephpleague/uri/releases)
[![Total Downloads](https://img.shields.io/packagist/dt/league/uri.svg?style=flat-square)](https://packagist.org/packages/league/uri)
Expand All @@ -10,50 +9,6 @@ The `Uri` package provides simple and intuitive classes to manage URIs in PHP.

> ⚠️ this is a sub-split, for development, pull requests and issues, visit: https://github.com/thephpleague/uri-src
You will be able to

- parse, build and resolve URIs
- create URIs from different sources (string, PHP environment, base URI, URI template, ...);
- handle internalisation;
- infer properties and features from URIs;

````php
<?php

use League\Uri\UriTemplate;

$template = 'https://api.twitter.com:443/{version}/search/{term:1}/{term}/{?q*,limit}#title';
$defaultVariables = ['version' => '1.1'];
$params = [
'term' => 'john',
'q' => ['a', 'b'],
'limit' => '10',
];

$uriTemplate = new UriTemplate($template, $defaultVariables);
$uri = $uriTemplate->expand($params);
// $uri is a League\Uri\Uri object

echo $uri->getScheme(); //displays "https"
echo $uri->getAuthority(); //displays "api.twitter.com:443"
echo $uri->getPath(); //displays "/1.1/search/j/john/"
echo $uri->getQuery(); //displays "q=a&q=b&limit=10"
echo $uri->getFragment(); //displays "title"
echo $uri;
//displays "https://api.twitter.com:443/1.1/search/j/john/?q=a&q=b&limit=10#title"
echo json_encode($uri);
//displays "https:\/\/api.twitter.com:443\/1.1\/search\/j\/john\/?q=a&q=b&limit=10#title"
````

Highlights
------

- Simple API
- [RFC3986][], [RFC3987][] and [RFC6570][] compliant
- Implements the `UriInterface` from [PSR-7][]
- Fully documented
- Framework Agnostic

System Requirements
-------

Expand Down

0 comments on commit 2ae362e

Please sign in to comment.