function file_get_remote_stream_wrappers in Remote Stream Wrapper 7
Return a list of remote stream wrappers.
3 calls to file_get_remote_stream_wrappers()
- file_is_scheme_remote in ./
remote_stream_wrapper.module - Check if a stream wrapper scheme is a remote stream wrapper.
- RemoteStreamWrapperTestCase::testBitMasks in ./
remote_stream_wrapper.test - Test STREAM_WRAPPERS_REMOTE bitmask and file_get_remote_stream_wrappers().
- remote_stream_wrapper_menu in ./
remote_stream_wrapper.module - Implements hook_menu().
File
- ./
remote_stream_wrapper.module, line 87 - Provides a remote stream wrapper and file field integration.
Code
function file_get_remote_stream_wrappers() {
$wrappers =& drupal_static(__FUNCTION__);
if (!isset($wrappers)) {
$wrappers = file_get_stream_wrappers(STREAM_WRAPPERS_REMOTE);
foreach ($wrappers as $scheme => $wrapper) {
if (empty($wrapper['remote'])) {
unset($wrappers[$scheme]);
}
}
//$wrappers = array_diff_key($wrappers, file_get_stream_wrappers(STREAM_WRAPPERS_LOCAL_NORMAL
}
return $wrappers;
}