Mercurial > hg > cmmr2012-drupal-site
comparison vendor/symfony/dom-crawler/Field/FileFormField.php @ 5:12f9dff5fda9 tip
Update to Drupal core 8.7.1
author | Chris Cannam |
---|---|
date | Thu, 09 May 2019 15:34:47 +0100 |
parents | a9cd425dd02b |
children |
comparison
equal
deleted
inserted
replaced
4:a9cd425dd02b | 5:12f9dff5fda9 |
---|---|
58 $info = pathinfo($value); | 58 $info = pathinfo($value); |
59 $name = $info['basename']; | 59 $name = $info['basename']; |
60 | 60 |
61 // copy to a tmp location | 61 // copy to a tmp location |
62 $tmp = sys_get_temp_dir().'/'.strtr(substr(base64_encode(hash('sha256', uniqid(mt_rand(), true), true)), 0, 7), '/', '_'); | 62 $tmp = sys_get_temp_dir().'/'.strtr(substr(base64_encode(hash('sha256', uniqid(mt_rand(), true), true)), 0, 7), '/', '_'); |
63 if (array_key_exists('extension', $info)) { | 63 if (\array_key_exists('extension', $info)) { |
64 $tmp .= '.'.$info['extension']; | 64 $tmp .= '.'.$info['extension']; |
65 } | 65 } |
66 if (is_file($tmp)) { | 66 if (is_file($tmp)) { |
67 unlink($tmp); | 67 unlink($tmp); |
68 } | 68 } |