$dateCreated = time(); $dateModified = time(); $userID = (int) $_POST['vUserID']; $countVideo = count($arrVideoTitle); for ($i = 0; $i < $countVideo; $i++) { $v = new TNT_Video(); $v->videoTitle = esc_html($arrVideoTitle[$i]); $v->videoCat = $videoCat; $v->videoType = $videoType; $v->videoLink = esc_url($arrVideoLink[$i]); $v->videoStatus = $arrVideoStatus[$i]; $v->videoOrder = $arrVideoOrder[$i]; $v->dateCreated = $dateCreated; $v->dateModified = $dateModified; $v->userID = $userID; $v->tntInsertVideo(); } // if($v->tntInsertVideo()) // { // $location = add_query_arg(array('m'=>1)); // } // else // { // $location = add_query_arg(array('m'=>0)); // } $location = add_query_arg(array('m' => 1)); Header("Location: {$location}"); } /** * Process: Edit Video */