Skip to content

Commit b68b91b

Browse files
committed
reverted saving to php://temp
1 parent 351e51f commit b68b91b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/ImageResize.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,12 +213,14 @@ public function save($filename, $image_type = null, $quality = null, $permission
213213
*/
214214
public function getImageAsString($image_type = null, $quality = null)
215215
{
216-
$string_temp = "php://temp";
216+
$string_temp = tempnam(sys_get_temp_dir(), '');
217217

218218
$this->save($string_temp , $image_type, $quality);
219219

220220
$string = file_get_contents($string_temp);
221221

222+
unlink($string_temp);
223+
222224
return $string;
223225
}
224226

0 commit comments

Comments
 (0)