UrlGenerator::getInternalPathFromRoute

protected UrlGenerator::getInternalPathFromRoute($name, SymfonyRoute $route, $parameters = array(), $query_params = array()) Gets the path of a route. Parameters $name: The route name or other debug message. \Symfony\Component\Routing\Route $route: The route object. array $parameters: An array of parameters as passed to \Symfony\Component\Routing\Generator\UrlGeneratorInterface::generate(). array $query_params: An array of query string parameter, which will get any extra values from $parameter

UrlGenerator::$requestStack

A request stack object. Type: \Symfony\Component\HttpFoundation\RequestStack File core/lib/Drupal/Core/Routing/UrlGenerator.php, line 32 Class UrlGenerator Generates URLs from route names and parameters. Namespace Drupal\Core\Routing Code protected $requestStack;

UrlGenerator::$decodedChars

Overrides characters that will not be percent-encoded in the path segment. The first two elements are the first two parameters of str_replace(), so if you override this variable you can also use arrays for the encoded and decoded characters. See also \Symfony\Component\Routing\Generator\UrlGenerator File core/lib/Drupal/Core/Routing/UrlGenerator.php, line 57 Class UrlGenerator Generates URLs from route names and parameters. Namespace Drupal\Core\Routing Code protected $decodedChars =

UrlGenerator::$pathProcessor

The path processor to convert the system path to one suitable for urls. Type: \Drupal\Core\PathProcessor\OutboundPathProcessorInterface File core/lib/Drupal/Core/Routing/UrlGenerator.php, line 39 Class UrlGenerator Generates URLs from route names and parameters. Namespace Drupal\Core\Routing Code protected $pathProcessor;

UrlGenerator::$routeProcessor

The route processor. Type: \Drupal\Core\RouteProcessor\OutboundRouteProcessorInterface File core/lib/Drupal/Core/Routing/UrlGenerator.php, line 46 Class UrlGenerator Generates URLs from route names and parameters. Namespace Drupal\Core\Routing Code protected $routeProcessor;

UrlGenerator::$context

Type: RequestContext File core/lib/Drupal/Core/Routing/UrlGenerator.php, line 25 Class UrlGenerator Generates URLs from route names and parameters. Namespace Drupal\Core\Routing Code protected $context;

Url::__construct

public Url::__construct($route_name, $route_parameters = array(), $options = array()) Constructs a new Url object. In most cases, use Url::fromRoute() or Url::fromUri() rather than constructing Url objects directly in order to avoid ambiguity and make your code more self-documenting. @todo Update this documentation for non-routed URIs in https://www.drupal.org/node/2346787 Parameters string $route_name: The name of the route array $route_parameters: (optional) An associative array of parameter

UrlGenerator

Generates URLs from route names and parameters. Hierarchy class \Drupal\Core\Routing\UrlGenerator implements UrlGeneratorInterface File core/lib/Drupal/Core/Routing/UrlGenerator.php, line 20 Namespace Drupal\Core\Routing Members Name Modifiers Type Description UrlGenerator::$context protected property UrlGenerator::$decodedChars protected property Overrides characters that will not be percent-encoded in the path segment. UrlGenerator::$pathProcessor protected

Url::validateUrl

public static Url::validateUrl(&$element, FormStateInterface $form_state, &$complete_form) Form element validation handler for #type 'url'. Note that #maxlength and #required is validated by _form_validate() already. File core/lib/Drupal/Core/Render/Element/Url.php, line 62 Class Url Provides a form element for input of a URL. Namespace Drupal\Core\Render\Element Code public static function validateUrl(&$element, FormStateInterface $form_state, &$complete_form) { $val

Url::toString

public Url::toString($collect_bubbleable_metadata = FALSE) Generates the string URL representation for this Url object. For an external URL, the string will contain the input plus any query string or fragment specified by the options array. If this Url object was constructed from a Drupal route or from an internal URI (URIs using the internal:, base:, or entity: schemes), the returned string will either be a relative URL like /node/1 or an absolute URL like http://example.com/node/1 depending o