Fala ai galera então segue abaixo esse script que gerar varios thumbs só que na hora da funcao imagejpeg() não sei no certo se o parametro esta correto não salva nada no diretorio especificado porque ? $fotos = $_FILES['fotos']; $quantidade=$_POST['quantidade']; define(MAX_WIDTH, 160); define(MAX_HEIGHT, 120); $d=aplic/intranet/servidor/gestao/treinamento_tecnico/thumb/teste/"; for($i = 0; $i < $quantidade; $i++) { $nome = $fotos['name][$i]; $tamanho = $fotos['size'][$i]; $tipo = $fotos['type'][$i]; $tmpname = $fotos['tmp_name'][$i]; $d.=$nome; $img=imagecreatefromjpeg($tmpname); $width = imagesx($img); $height = imagesy($img); $scale = min(MAX_WIDTH/$width, MAX_HEIGHT/$height); if ($scale < 1) { $new_width = floor($scale * $width); $new_height = floor($scale * $height); $tmp_img = imagecreatetruecolor($new_width, $new_height); $new_img=imagecopyresized($tmp_img, $img, 0, 0, 0, 0, $new_width, $new_height, $width, $height); imagejpeg($tmp_img,$d); } }