$params = [ 'foo' => 'bar', 'baz' => 'qux', ]; $queryString = http_build_query($params); $url = 'https://example.com/path?' . $queryString;
$assetPath = 'css/style.css'; $url = url($assetPath);The PHP URL asset library is included as part of the Laravel framework, which is a popular PHP web application framework.