Example #1
0
    }
    $_POST['formToken'] = $converter->GetUniqueID();
}
// On form submission, check for valid submission and video URL
$validFormSubmission = isset($_POST['submitForm']) && (isset($_POST['formToken']) && $_POST['formToken'] == $converter->GetUniqueID() || isset($_POST['bookmarklet']));
$validVideoUrl = false;
$vidURL = trim($_POST['videoURL']);
if ($validFormSubmission) {
    $moreOptions = array();
    if (!empty($_POST['volume'])) {
        $moreOptions['volume'] = trim($_POST['volume']);
    }
    $validVideoUrl = $converter->ValidateConversionForm($vidURL, $_POST['ftype'], true, $moreOptions);
    if ($validVideoUrl) {
        $vidInfo = $converter->GetVidInfo();
        $extractor = $converter->GetExtractor();
        $currentVideoId = method_exists($extractor, 'GetPageUrlSuffix') ? $extractor->GetPageUrlSuffix() : $vidInfo['id'];
    }
}
?>
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1" />
	<?php 
include 'inc/page_meta_data.php';
?>
	<link rel="stylesheet" type="text/css" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.9.2/themes/base/jquery-ui.css" />
	<link rel="stylesheet" type="text/css" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/css/bootstrap.min.css" />