You are here

public function oEmbedStream::getExternalUrl in oEmbed 8

Returns a web accessible URL for the resource.

This function should return a URL that can be embedded in a web page and accessed from a browser. For example, the external URL of "youtube://xIpLd0WQKCY" might be "http://www.youtube.com/watch?v=xIpLd0WQKCY".

Return value

string Returns a string containing a web accessible URL for the resource.

Overrides StreamWrapperInterface::getExternalUrl

2 calls to oEmbedStream::getExternalUrl()
oEmbedStream::realpath in src/StreamWrapper/oEmbedStream.php
Base implementation of realpath().
oEmbedStream::stream_open in src/StreamWrapper/oEmbedStream.php
Support for fopen(), file_get_contents(), file_put_contents() etc.

File

src/StreamWrapper/oEmbedStream.php, line 90
Create a oEmbed Stream Wrapper class.

Class

oEmbedStream
@file Create a oEmbed Stream Wrapper class.

Namespace

Drupal\oembed\StreamWrapper

Code

public function getExternalUrl() {
  return rawurldecode(substr($this
    ->getUri(), 9));
}