URI - Uniform Resource Identifiers (absolute and relative)
$u1 = URI->new("http://www.perl.com"); $u2 = URI->new("foo", "http"); $u3 = $u2->abs($u1); $u4 = $u3->clone; $u5 = URI->new("HTTP://WWW.perl.com:80")->canonical; $str = $u->as_string; $str = "$u"; $scheme = $u->scheme; $opaque = $u->opaque; $path = $u->path; $frag = $u->fragment; $u->scheme("ftp"); $u->host("ftp.perl.com"); $u->path("cpan/");
This module implements the URI class. Objects of this class represent Uniform Resource Identifiers (URI) references as specified in RFC 2396.
URI
A Uniform Resource Identifier is a compact string of characters for identifying an abstract or physical resource. A Uniform Resource Identifier can be further classified either a Uniform Resource Locator (URL) or a Uniform Resource Name (URN). The distinction between URL and URN is not reflected in the abstractions provided by the URI class.
The following methods are provided:
$uri->_scheme
Generic methods:
Server methods:
$uri->_port()
URI::WithBase, URI::Escape, URI::Heuristic
RFC 2396
Copyright 1995-1998 Gisle Aas.
Copyright 1995 Martijn Koster.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
This module is based on the URI::URL module, which in turn was (distantly) based on the wwwurl.pl code in the libwww-perl for perl4 developed by Roy Fielding, as part of the Arcadia project at the University of California, Irvine, with contributions from Brooks Cutter.
URI::URL
wwwurl.pl
URI::URL was developed by Gisle Aas, Tim Bunce, Roy Fielding and Martijn Koster with input from other people on the libwww-perl mailing list.
To install URI, copy and paste the appropriate command in to your terminal.
cpanm
cpanm URI
CPAN shell
perl -MCPAN -e shell install URI
For more information on module installation, please visit the detailed CPAN module installation guide.