URI::Split(3)
πΈ NAME πΈ
okay so bestie, this is URI::Split(3) from the User Contributed Perl Documentation, and it's literally here to Parse and compose URI strings π no cap.
β¨ SYNOPSIS β¨
use URI::Split qw(uri_split uri_join);
($scheme, $auth, $path, $query, $frag) = uri_split($uri);
$uri = uri_join($scheme, $auth, $path, $query, $frag);
Like, that's the whole vibe: split a URI into pieces, then put it back together π.
π DESCRIPTION π
Provides functions to parse and compose URI strings. The following functions are provided:
π¦ ($scheme, $auth, $path, $query, $frag) = uri_split($uri) π¦
Breaks up a URI string into its component parts. An undef value is returned for those parts that are not present. The $path part is always present (but can be the empty string) and is thus never returned as undef.
π«Ά heads up: no sensible value is returned if this function is called in a scalar context. Like, don't do that, okay?
π§ $uri = uri_join($scheme, $auth, $path, $query, $frag) π§
Puts together a URI string from its parts. Missing parts are signaled by passing undef for the corresponding argument.
Minimal escaping is applied to parts that contain reserved chars that would confuse a parser. For instance, any occurrence of '?' or '#' in $path is always escaped, as it would otherwise be parsed back as a query or fragment. Slay, parser-friendly π
.
π SEE ALSO π
URIURI::Escape
π COPYRIGHT π
Copyright 2003, Gisle Aas
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
okay bestie, that's the whole page β catch you later! This one's from perl v5.42.0, dated 2026-09-02 πβ¨π¦
π¦ where this page comes from
- opensuse-leap 16.0: perl-URI 5.310.0-160000.3.1 Β· Artistic-1.0 OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms