File::url

public File::url($rel = 'canonical', $options = array())

Overrides Entity::url

See also

file_url_transform_relative()

File

core/modules/file/src/Entity/File.php, line 73

Class

File
Defines the file entity class.

Namespace

Drupal\file\Entity

Code

public function url($rel = 'canonical', $options = array()) {
  return file_create_url($this->getFileUri());
}
doc_Drupal
2016-10-29 09:13:18
Comments
Leave a Comment

Please login to continue.