if (strrpos($key, 'vFiledata') === false) { continue; } $num = substr($key, strlen('vFiledata')); if (!empty($_FILES['vFiledata' . $num]['name'])) { if (!empty($_POST['savevideo'][$num])) { $strOldFile = $arrGPic['FileSavePath'] . 'f/' . $_POST['savevideo'][$num]; } else { $strOldFile = ''; } if (is_file($strOldFile)) { // 视频文件删除 unlink($strOldFile); } $arrTemp = array(); $arrTemp['video'] = $objWebInit->uploadInfoFile($_FILES['vFiledata' . $num], $num, $_POST['id'], array('.flv')); if (!empty($_POST['video_narrate' . $num])) { $arrTemp['video_narrate'] = $_POST['video_narrate' . $num]; } if (!empty($_POST['video_title' . $num])) { $arrTemp['video_title'] = $_POST['video_title' . $num]; } if (!empty($_POST['video_time' . $num])) { $arrTemp['video_time'] = $_POST['video_time' . $num]; } $_POST['video'][$num] = $arrTemp; } } //替换旧视频图片和新视频图片上传 sleep(1); foreach ($_FILES as $key => $val) {