function file_uri_scheme in Drupal 8
Same name and namespace in other branches
- 7 includes/file.inc \file_uri_scheme()
Returns the scheme of a URI (e.g. a stream).
Deprecated
in drupal:8.8.0 and is removed from drupal:9.0.0. Use Drupal\Core\StreamWrapper\StreamWrapperManagerInterface::getScheme() instead.
See also
https://www.drupal.org/node/3035273
Related topics
1 call to file_uri_scheme()
- FileSystemDeprecationTest::testDeprecatedFileUriScheme in core/
tests/ Drupal/ KernelTests/ Core/ File/ FileSystemDeprecationTest.php - @expectedDeprecation file_uri_scheme() is deprecated in drupal:8.0.0 and will be removed before drupal:9.0.0. Use \Drupal\Core\StreamWrapper\StreamWrapperManagerInterface::getScheme() instead. See https://www.drupal.org/node/3035273
File
- core/
includes/ file.inc, line 105 - API for handling file uploads and server file management.
Code
function file_uri_scheme($uri) {
@trigger_error('file_uri_scheme() is deprecated in drupal:8.0.0 and will be removed before drupal:9.0.0. Use \\Drupal\\Core\\StreamWrapper\\StreamWrapperManagerInterface::getScheme() instead. See https://www.drupal.org/node/3035273', E_USER_DEPRECATED);
return StreamWrapperManager::getScheme($uri);
}