public function EasyRdf_ParsedUri::toString in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/easyrdf/easyrdf/lib/EasyRdf/ParsedUri.php \EasyRdf_ParsedUri::toString()
Convert the parsed URI back into a string
Return value
string The URI as a string
1 call to EasyRdf_ParsedUri::toString()
- EasyRdf_ParsedUri::__toString in vendor/
easyrdf/ easyrdf/ lib/ EasyRdf/ ParsedUri.php - Magic method to convert the URI, when casted, back to a string
File
- vendor/
easyrdf/ easyrdf/ lib/ EasyRdf/ ParsedUri.php, line 313
Class
- EasyRdf_ParsedUri
- A RFC3986 compliant URI parser
Code
public function toString() {
$str = '';
if ($this->scheme !== null) {
$str .= $this->scheme . ':';
}
if ($this->authority !== null) {
$str .= '//' . $this->authority;
}
$str .= $this->path;
if ($this->query !== null) {
$str .= '?' . $this->query;
}
if ($this->fragment !== null) {
$str .= '#' . $this->fragment;
}
return $str;
}