Esempio n. 1
0
 *    You should have received a copy of the GNU General Public License
 *    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
defined( '_JEXEC' ) or die( 'Direct Access to this location is not allowed.' );

global $hwdvsItemid, $smartyvs;
$c = hwd_vs_Config::get_instance();

require_once(JPATH_SITE.DS.'administrator'.DS.'components'.DS.'com_hwdvideoshare'.DS.'libraries'.DS.'warp'.DS.'infin-lib.php');

$videoInfo = "title=".htmlspecialchars($title)."&description=".htmlspecialchars($description)."&category_id=".htmlspecialchars($category_id)."&tags=".htmlspecialchars($tags)."&public_private=".htmlspecialchars($public_private)."&allow_comments=".htmlspecialchars($allow_comments)."&allow_embedding=".htmlspecialchars($allow_embedding)."&allow_ratings=".htmlspecialchars($allow_ratings);

$accountKey = $c->warpAccountKey;
$secretKey = $c->warpSecretKey;
$infinVideo = new InfinovationVideo($accountKey, $secretKey);
$newVideoGuid = $infinVideo->getNewVideoGuid();
$uploadSignature = $infinVideo->generateUploadSignature($newVideoGuid);
$postUrl = urlencode(JRoute::_("index.php?option=com_hwdvideoshare&Itemid=".$hwdvsItemid."&task=uploadconfirmwarp&videoGuid=$newVideoGuid&$videoInfo"));
$flashvar = "AccountKey=$accountKey&VideoGuid=$newVideoGuid&Signature=$uploadSignature&PostURL=$postUrl&AllowWebcam=1&SizeLimit=0&RecordingLimit=0&MaxDuration=0";
$ul =  '<script type="text/javascript" language="javascript" src="'.JURI::base().'/components/com_hwdvideoshare/assets/js/AC_OETags.js"></script>
		<script type="text/javascript" language="javascript">
		<!--
		var requiredMajorVersion = 9;
		var requiredMinorVersion = 0;
		var requiredRevision = 115;
		var hasProductInstall = DetectFlashVer(6, 0, 65);
		var hasRequestedVersion = DetectFlashVer(requiredMajorVersion, requiredMinorVersion, requiredRevision);

		if ( hasProductInstall && !hasRequestedVersion ) {
			var MMPlayerType = (isIE == true) ? "ActiveX" : "PlugIn";
			var MMredirectURL = window.location;