Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Resource.php

function Resource::getHtml

Returns the HTML representation of the resource.

Only applies to 'rich' and 'video' resources.

Return value

string|null The HTML representation of the resource, if it has one.

File

core/modules/media/src/OEmbed/Resource.php, line 482

Class

Resource
Value object representing an oEmbed resource.

Namespace

Drupal\media\OEmbed

Code

public function getHtml() {
    return isset($this->html) ? (string) $this->html : NULL;
}
RSS feed
Powered by Drupal