0) $path = 'https://uf.joywork.ru/upload/reqs/'.$file['req_id'].'/'.$file['guid'].'.'.$file['type']; $files[] = [ 'guid' => $file['guid'], 'name' => $file['name'], 'type' => $file['type'], 'path' => $path, ]; } } echo json_encode($files); }