Exemple #1
0
 public function url(array $args = [])
 {
     $url = PRIME_URI;
     $parts = Url::parse($url, true);
     $parts['vars'] = array_replace($parts['vars'], $args);
     return Url::build($parts);
 }
Exemple #2
0
 public function url(array $args = [])
 {
     $grav = Grav::instance();
     $url = $grav['uri']->url;
     $parts = Url::parse($url, true);
     $parts['vars'] = array_replace($parts['vars'], $args);
     return Url::build($parts);
 }