2017 © Pedro Peláez
 

library url-parser

URL parser for PHP, allow you to extract every piece of information of a URL/HOST, structured and clean.

image

max13/url-parser

URL parser for PHP, allow you to extract every piece of information of a URL/HOST, structured and clean.

  • Tuesday, January 14, 2014
  • by Max13
  • Repository
  • 1 Watchers
  • 3 Stars
  • 477 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 1 Open issues
  • 10 Versions
  • 0 % Grown

The README.md

MXUrlParser-PHP

Description

MXUrlParser is capable of parsing a complete URL and extract some parts of it like the URL parts (using php parse_url() function) and some domain name parts (using Mozilla public suffix list)., (*1)

Available parts are (Assuming URL is https://dev.api.example.co.uk/1/2/3?key=val#anchor):, (*2)

  • scheme: https
  • host: dev.api.example.co.uk
  • path: /1/2/3
  • query: key=val
  • fragment: anchor
  • subdomain: dev
  • domain: api.example
  • tld: co.uk

Required

  • PHP >= 5.3

How to download

There are several ways to download MxUrlParser-PHP:, (*3)

  • Install with composer ("max13/url-parser": "dev-master")
  • Clone the github repository with git clone <repo> [<dest>]
  • Download the zip file on github directly
  • Try to find another one by yourself :/

Then place it where you want (readable location, in order to load it)., (*4)

How to use

Let's say your URL is: dev.api.example.co.uk/1/2/3?key=val#anchor, (*5)

You can parse it with the MX\UrlParser\UrlParser class:, (*6)

scheme; // === null
$p_url->host; // == 'dev.api.example.co.uk'
$p_url->subdomain; // == 'dev'
$p_url->tld; // == 'co.uk'
*/
?>

That's it, as simple as this...!, (*7)

The Versions

14/01 2014

dev-master

9999999-dev http://github.com/Max13/MXUrlParser-PHP

URL parser for PHP, allow you to extract every piece of information of a URL/HOST, structured and clean.

  Sources   Download

CC-BY-NC-SA-3.0

The Requires

  • php >=5.3.0

 

The Development Requires

by Adnan RIHAN

laravel parser url url-parser

25/11 2013

v1.0.0

1.0.0.0 http://github.com/Max13/MXUrlParser-PHP

URL parser for PHP, allow you to extract every piece of information of a URL/HOST, structured and clean.

  Sources   Download

CC-BY-NC-SA-3.0

The Requires

  • php >=5.3.0

 

The Development Requires

by Adnan RIHAN

laravel parser url url-parser

24/11 2013

v0.1.4-p2

0.1.4.0-patch2 http://github.com/Max13/MXUrlParser-PHP

URL parser for PHP, allow you to extract every piece of information of a URL/HOST, structured and clean.

  Sources   Download

CC-BY-NC-SA-3.0

The Requires

  • php >=5.3.0

 

The Development Requires

by Adnan RIHAN

laravel parser url url-parser

24/11 2013

v0.1.4-p1

0.1.4.0-patch1 http://github.com/Max13/MXUrlParser-PHP

URL parser for PHP, allow you to extract every piece of information of a URL/HOST, structured and clean.

  Sources   Download

CC-BY-NC-SA-3.0

The Requires

  • php >=5.3.0

 

The Development Requires

by Adnan RIHAN

laravel parser url url-parser

24/11 2013

v0.1.4

0.1.4.0 http://github.com/Max13/MXUrlParser-PHP

URL parser for PHP, allow you to extract every piece of information of a URL/HOST, structured and clean.

  Sources   Download

CC-BY-NC-SA-3.0

The Requires

  • php >=5.3.0

 

The Development Requires

by Adnan RIHAN

laravel parser url url-parser

14/11 2013

v0.1.3-patch1

0.1.3.0-patch1 http://github.com/Max13/MXUrlParser-PHP

URL parser for PHP, allow you to extract every piece of information of a URL/HOST, structured and clean.

  Sources   Download

CC-BY-NC-SA-3.0

The Requires

 

by Adnan RIHAN

laravel parser url url-parser

14/11 2013

v0.1.3

0.1.3.0 http://github.com/Max13/MXUrlParser-PHP

URL parser for PHP, allow you to extract every piece of information of a URL/HOST, structured and clean.

  Sources   Download

CC-BY-NC-SA-3.0

The Requires

 

by Adnan RIHAN

laravel parser url url-parser

14/11 2013

v0.1.2

0.1.2.0 http://github.com/Max13/MXUrlParser-PHP

URL parser for PHP, allow you to extract every piece of information of a URL/HOST, structured and clean.

  Sources   Download

CC-BY-NC-SA-3.0

The Requires

 

by Adnan RIHAN

laravel parser url url-parser

14/11 2013

v0.1.1

0.1.1.0 http://github.com/Max13/MXUrlParser-PHP

URL parser for PHP, allow you to extract every piece of information of a URL/HOST, structured and clean.

  Sources   Download

CC-BY-NC-SA-3.0

The Requires

 

by Adnan RIHAN

laravel parser url url-parser

14/11 2013

v0.1.0

0.1.0.0 http://github.com/Max13/MXUrlParser-PHP

URL parser for PHP, allow you to extract every piece of information of a URL/HOST, structured and clean.

  Sources   Download

CC-BY-NC-SA-3.0

The Requires

 

by Adnan RIHAN

laravel parser url url-parser