You are here

public function UrlResolverInterface::getResourceUrl in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/media/src/OEmbed/UrlResolverInterface.php \Drupal\media\OEmbed\UrlResolverInterface::getResourceUrl()
  2. 9 core/modules/media/src/OEmbed/UrlResolverInterface.php \Drupal\media\OEmbed\UrlResolverInterface::getResourceUrl()

Builds the resource URL for a media asset URL.

Parameters

string $url: The media asset URL.

int $max_width: (optional) Maximum width of the oEmbed resource, in pixels.

int $max_height: (optional) Maximum height of the oEmbed resource, in pixels.

Return value

string Returns the resource URL corresponding to the given media item URL.

1 method overrides UrlResolverInterface::getResourceUrl()
UrlResolver::getResourceUrl in core/modules/media/src/OEmbed/UrlResolver.php
Builds the resource URL for a media asset URL.

File

core/modules/media/src/OEmbed/UrlResolverInterface.php, line 43

Class

UrlResolverInterface
Defines the interface for the oEmbed URL resolver service.

Namespace

Drupal\media\OEmbed

Code

public function getResourceUrl($url, $max_width = NULL, $max_height = NULL);