aboutsummaryrefslogtreecommitdiff
path: root/mod/livestream/actions/new.php
blob: 0deb952755dc720fbce6eaf4b71fbd78a7b2149c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
<?php 
	require_once "{$CONFIG->pluginspath}livestream/libraries.php";

	$params = Array();
	$params['title']     = get_input('title', '');
	$params['mediatype'] = get_input('mediatype', '');
	$params['src']       = get_input('src', '');
	$params['width']     = get_input('width', '');
	$params['height']    = get_input('height', '');

	$params['owner_guid']     = page_owner();
	$params['container_guid'] = get_input('container_guid', '');
	
	$myObject = livestream_addnew($params);
	
	if($myObject){
		$container = livestream_get_container($myObject);
		forward('livestream/'.$container->username);
	}else{
		elgg_echo ("livestream:internal_error");
	}
	
?>