Re orderd the functions of video.php.