1.20.x stream_wrappers.inc BackdropPrivateStreamWrapper::getExternalUrl()

Overrides getExternalUrl().

Return the HTML URI of a private file.

Overrides BackdropStreamWrapperInterface::getExternalUrl

File

includes/stream_wrappers.inc, line 956
Backdrop stream wrapper interface.

Class

BackdropPrivateStreamWrapper
Backdrop private (private://) stream wrapper class.

Code

function getExternalUrl() {
  $path = str_replace('\\', '/', $this->getTarget());
  return url('system/files/' . $path, array('absolute' => TRUE));
}