Set Session through php function.
<?php
function addtovedio($name){
if(is_array($_SESSION['video'])){
$max=count($_SESSION['video']);
$_SESSION['video'][$max]['name']=$name;
echo $_SESSION['video'];
}
else{
$_SESSION['video']=array();
$_SESSION['video'][0]['name']=$name;
}
}
?>
function addtovedio($name){
if(is_array($_SESSION['video'])){
$max=count($_SESSION['video']);
$_SESSION['video'][$max]['name']=$name;
echo $_SESSION['video'];
}
else{
$_SESSION['video']=array();
$_SESSION['video'][0]['name']=$name;
}
}
?>