- <?php
- /**
- * <b>Multimedia</b><br />
- * The multimedia section shows all of the information and downloading of multimedia.
- * There are two types of multimedia, Audio and Video.<br />
- * Audio Views available are:
- * - Specific Category
- * - All Hard Questions
- * - New Audio
- * Audio has transcripts that are displayed in HTML and PDF.<br />
- * This section is searchable (audio only).<br />
- * This section links to the contact form to submit a hard question.
- * @author Kristen O'Brien <kristen_paristemi-com>
- * @copyright Copyright 2004, Kristen O'Brien
- * @license http://opensource.org/licenses/gpl-license.php GNU Public License
- * @link http://www.paristemi.com Paristemi Main Site
- * @package paristemi
- * @subpackage paristemi_business_logic
- * @since Build 0.3
- * @version Build 0.7
- * @filesource
- */
- /**
- * Include the constants file and all of the files in the include list
- */
- if(ltrim(dirname($_SERVER['SCRIPT_FILENAME'])) == "" || !file_exists($_SERVER['DOCUMENT_ROOT']."/constants.php")) {
- if(!file_exists("../constants.php")) { require_once("../public_html/constants.php"); }
- else { require_once("../constants.php"); }
- }
- else { require_once($_SERVER['DOCUMENT_ROOT']."/constants.php"); }
- foreach($INCLUDE_LIST as $includefile) { require_once $includefile; }
-
- $db = new Database();
- $db_multimedia = $db->GetClass('multimedia');
- $smarty = UtilSmarty::createSmarty();
- $id="";$type="";$listtype="";$cat="";$trans="";$lbegin=0;$scount=0;$dlpdf="";$transcript="";
- $searchterm="";$stitle="";$sdesc="";$stopic="";$scntflg=false;$searchflg=false;
-
- if(getenv("QUERY_STRING")) {
- if(isset($HTTP_GET_VARS['id'])) {$id = $HTTP_GET_VARS['id'];}
- if(isset($HTTP_GET_VARS['type'])) {$type = $HTTP_GET_VARS['type'];}
- if(isset($HTTP_GET_VARS['listtype'])) {$listtype = $HTTP_GET_VARS['listtype'];}
- if(isset($HTTP_GET_VARS['cat'])) {$cat = $HTTP_GET_VARS['cat'];$listtype='cat';}
- if(isset($HTTP_GET_VARS['trans'])) { $trans = $HTTP_GET_VARS['trans']; }
- if(isset($HTTP_GET_VARS['SearchTerm'])) {$searchterm = $HTTP_GET_VARS['SearchTerm'];$searchflg=true;}
- if(isset($HTTP_GET_VARS['Title'])) {$stitle = $HTTP_GET_VARS['Title'];}
- if(isset($HTTP_GET_VARS['Description'])) {$sdesc = $HTTP_GET_VARS['Description'];}
- if(isset($HTTP_GET_VARS['Category'])) {$scategory = $HTTP_GET_VARS['Category'];}
- if(isset($HTTP_GET_VARS['Transcript'])) { $transcript = $HTTP_GET_VARS['Transcript'];}
- if(isset($HTTP_GET_VARS['dlpdf'])) { $dlpdf = $HTTP_GET_VARS['dlpdf'];}
- if(isset($HTTP_GET_VARS['lbegin'])) {$lbegin = $HTTP_GET_VARS['lbegin'];}
- if(isset($HTTP_GET_VARS['scount'])) {$scount = $HTTP_GET_VARS['scount'];$scntflg=true;}
- }
- if($dlpdf == "yes" && $id != null && $type == "audio") {
- $value =& $db_multimedia->GetMultimediaAudioItem($id); $pdflink="";
- if($value->ALinkStream) {
- $pdflink .= "<a href=\"".$value->ALinkStream."\">".$S_LISTEN."</a>"; }
- if($value->ALinkDownload) {
- $pdflink .= " <a href=\"".$value->ALinkDownload."\">".$S_DOWNLOAD;
- $pdflink .= "(".UtilFiles::GetFilesize($value->ALinkDownload).")</a>";
- }
- if($pdflink != null) { $pdflink = "\r\n".$pdflink; }
- $text =& UtilBible::ParseVerses($value->Transcript);
- UtilFiles::CreatePDF($value->Title,$text,$value->Description.$pdflink,
- $HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.$MULTIMEDIA_FILE."?id=".$value->ID.'&type=audio');
- }
-
- if($type != "") {
- $pagesubtitle = ucwords(strtolower($type));
- if($cat != "") { $pagesubtitle .= " - ".str_replace("_"," ",$cat); }
- else if($listtype == 'hq') { $pagesubtitle .= " - ".$S_HARD_QUESTIONS; }
- else if($listtype == 'new') { $pagesubtitle .= " - ".$S_NEW; }
- else if($listtype == 'all') { $pagesubtitle .= " - ".$S_ALL; }
- else if($id != "") {
- if($type == "audio") { $value =& $db_multimedia->GetMultimediaAudioItem($id); }
- else if($type == "video") { $value =& $db_multimedia->GetMultimediaVideoItem($id); }
- $pagesubtitle .= " - ".$value->Title;
- }
- }
- else if($searchterm != "") { $pagesubtitle = $S_SEARCH." - ".ucwords(strtolower($searchterm)); }
- else { $pagesubtitle = $S_RECENTLY_ADDED; }
-
- require_once $HTTP_DOCUMENT_ROOT.$INCLUDE_PATH.$HEADER.
- "?pagetitle=".str_replace(" ","%20",htmlentities($S_MULTIMEDIA)).
- "&pagesubtitle=".str_replace(" ","%20",htmlentities(stripslashes($pagesubtitle))).
- "&pagedesc=".str_replace(" ","%20",htmlentities($CHURCH_NAME." ".$S_DESC_MULTIMEDIA));
-
- $data = $db_multimedia->GetMultimediaAudioCategories();
- $sidesections = array();
- if($data != null) {
- $sidesection = array();
- $sidesection['Links'] = array();
- $sidesection['Title'] = $S_AUDIO;
- foreach ($data as $value) {
- $sidesection['Links'][] = array('LinkPath'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.
- $MULTIMEDIA_FILE."?type=audio&cat=".
- str_replace(" ", "_", $value),'LinkText'=>$value);
- }
- $sidesection['Links'][] = array('LinkPath'=>"",'LinkText'=>"break");
- if($MULTIMEIDA_NUM_NEW != 0) {
- $sidesection['Links'][] = array('LinkPath'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.
- $MULTIMEDIA_FILE."?type=audio&listtype=new",
- 'LinkText'=>$S_NEW." ".$S_AUDIO);
- }
- if($db_multimedia->GetHardQuestionsCount() != 0) {
- $sidesection['Links'][] = array('LinkPath'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.
- $MULTIMEDIA_FILE."?type=audio&listtype=hq",
- 'LinkText'=>$S_ALL." ".$S_HARD_QUESTIONS);
- }
- if($SHOW_ASK_HARD_QUESTION) {
- $sidesection['Links'][] = array('LinkPath'=>$HTTP_DOCUMENT_ROOT.$FEEDBACK_FILE.
- "?feedbackname=Hard%20Questions",
- 'LinkText'=>$S_ASK_HQ);
- }
- $sidesections[] = $sidesection;
- }
- $vdata = $db_multimedia->GetMultimediaVideoCategories();
- if($vdata != null) {
- $sidesection = array();
- $sidesection['Links'] = array();
- $sidesection['Title'] = $S_VIDEO;
- foreach ($vdata as $value) {
- $sidesection['Links'][] = array('LinkPath'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.
- $MULTIMEDIA_FILE."?type=video&cat=".
- str_replace(" ", "", $value),'LinkText'=>$value);
- }
- $sidesections[] = $sidesection;
- }
- $smarty->assign('sidesections',$sidesections);
-
- $icondescriptions = array();
- if($data != null) {
- $icondescriptions[] = array('src'=>$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.$MULTIMEDIA_AUDIO_IMG,
- 'alt'=>$S_AUDIO." ".$S_STREAMING,'desc'=>$S_AUDIO." (".$S_STREAMING.")");
- $icondescriptions[] = array('src'=>$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.$MULTIMEDIA_AUDIO_IMG_DL,
- 'alt'=>$S_AUDIO." ".$S_DOWNLOAD,'desc'=>$S_AUDIO." (".$S_DOWNLOAD.")");
- $icondescriptions[] = array('src'=>$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.$MULTIMEDIA_TRANS_IMG,
- 'alt'=>$S_TRANSCRIPT,'desc'=>$S_TRANSCRIPT);
- }
- if($SHOW_PDF_DL) {
- $icondescriptions[] = array('src'=>$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.$PDF_IMG,
- 'alt'=>"PDF",'desc'=>'PDF '.$S_TRANSCRIPT);
- }
- if($vdata != null) {
- $icondescriptions[] = array('src'=>$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.$MULTIMEDIA_VIDEO_IMG,
- 'alt'=>$S_VIDEO,'desc'=>$S_VIDEO);
- }
- $smarty->assign('icondescriptions',$icondescriptions);
-
- $smarty->assign('searchformname','audiosearch');
- $smarty->assign('searchformfile',$MULTIMEDIA_FILE);
- $smarty->assign('hiddensearchinputs',array(array('name'=>'type','value'=>'audio')));
- $smarty->assign('searchconstraints',array(
- array('name'=>'Title','title'=>$S_TITLE),
- array('name'=>'Description','title'=>$S_DESC),
- array('name'=>'Category','title'=>$S_CATEGORY),
- array('name'=>'Transcript','title'=>$S_TRANSCRIPT)));
- $smarty->assign('searchsubmittitle',$S_AUDIO." ".$S_SEARCH);
-
- if(getenv("QUERY_STRING")) {
- if($type == "audio") {
- if($searchflg) {
- if($searchterm == "") {
- $finalresults =& $db_multimedia->GetMultimediaAudioByLimit($LISTING_LIMIT,$lbegin);
- $scount = count($db_multimedia->GetMultimediaAudio());
- $sterm = "";
- }
- else {
- $sterm = $searchterm;
- $atype = array();
- if($sdesc != null) { $atype[] = "description"; }
- if($stitle != null) { $atype[] = "title"; }
- if($scategory != null) { $atype[] = "category"; }
- if($transcript != null) { $atype[] = "transcript"; }
-
- $finalresults =& $db_multimedia->SearchAudioType($searchterm,$atype,$LISTING_LIMIT,$lbegin);
- if(!$scntflg) {$scount = $db_multimedia->SearchAudioCount($searchterm,$atype);}
- }
- if($finalresults != null) { $listtype = 'search'; }
- else {
- $smarty->assign('heading',$S_SEARCH." ".$S_RESULTS);
- $smarty->assign('notice',$N_SEARCH_MULTIMEDIA_NONE);
- }
- }
- if($id != null) {
- $value =& $db_multimedia->GetMultimediaAudioItem($id);
- $tblheader = "<h2>".$value->Title."</h2>";
- $tblarr = array();
- $tblclass = "tbl-listing";
- $tbltdclass = array("tbl-listing-title","tbl-listing-item");
- if($value->ALinkStream) {
- $tblheader .= "<a href=\"".$value->ALinkStream."\">";
- $tblheader .= "<img border=\"0\" align=\"middle\" src=\"".$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.$MULTIMEDIA_AUDIO_IMG;
- $tblheader .= "\" alt=\"Audio Stream\" border=\"0\" \></a>";
- $tblheader .= " <a href=\"".$value->ALinkStream."\">".$S_LISTEN."</a>";
- }
- if($value->ALinkDownload) {
- $tblheader .= " | <a href=\"".$value->ALinkDownload."\">".$S_DOWNLOAD;
- $tblheader .= " <span class=\"filesize\">";
- $tblheader .= "(".UtilFiles::GetFilesize($value->ALinkDownload).")</span></a>";
- }
- if($trans != "") {
- $tbltdclass = array("tbl-listing-item");
- array_push($tblarr,array(nl2br($value->Transcript)));
- }
- else {
- array_push($tblarr,array($S_CATEGORY,$value->Category));
- if ($value->Description != null) {
- array_push($tblarr,array($S_DESC,stripslashes($value->Description)));
- }
- if ($value->BookReference != "" && $value->StartVerse != "" && $value->StopVerse != ""
- && $value->BookReference != "No Reference"
- && $value->StartVerse != 0 && $value->StopVerse != 0) {
- $reference = $value->BookReference." ".trim($value->StartVerse);
- if(trim($value->StartVerse) != trim($value->StopVerse)) {
- $reference .= "-".trim($value->StopVerse); }
- array_push($tblarr,array($S_BIBLE_REFERENCE,UtilBible::DisplayVerseLink($reference)));
- }
- if($value->Transcript != null) {
- $transtext = '<a href="'.$HTTP_DOCUMENT_ROOT.
- $MULTIMEDIA_DIR.$MULTIMEDIA_FILE.'?id='.$value->ID.
- '&trans=yes&type=audio">'.$S_VIEW.' '.$S_TRANSCRIPT.'</a>';
- $pdftext = "";
- if($SHOW_PDF_DL) {
- $pdftext = '<a href="'.$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.$MULTIMEDIA_FILE.
- "?id=".$value->ID."&type=audio&dlpdf=yes\">".$S_DOWNLOAD." ".$S_TRANSCRIPT." [PDF]</a>";
- }
- array_push($tblarr,array($S_TRANSCRIPT,$transtext.' '.$pdftext));
- }
- }
- $smarty->assign('printtable',UtilHtml::createTable($tblarr,$tblheader,$tblclass,"","",$tbltdclass));
- }
-
- else if($listtype != null) {
- $newdata =& $db_multimedia->GetMultimediaAudioRecent($MULTIMEIDA_NUM_NEW);
- $newarr = array();
- foreach($newdata as $newid) { $newarr[$newid->ID] = $newid->ID; }
- $slinktext = "";
- switch($listtype) {
- case 'search' : $data = $finalresults;
- $headertitle = $S_SEARCH." ".$S_RESULTS;
- $scount = $scount;
- $linktext = "&SearchTerm=".$sterm."&Title=".
- $stitle."&Category=".$scategory."&Description=".$sdesc;
- break;
- case 'all' : $data = $db_multimedia->GetMultimediaAudioByLimit($LISTING_LIMIT,$lbegin);
- $headertitle = $S_ALL." ".$S_AUDIO." ".$S_MULTIMEDIA;
- $scount = $db_multimedia->GetAllAudioCount();
- $linktext = "&listtype=all&type=audio";
- break;
- case 'new' : $data = $newdata;
- $headertitle = $S_NEW." ".$S_AUDIO." ".$S_MULTIMEDIA;
- $scount = count($data);
- $linktext = "&listtype=new&type=audio";
- break;
- case 'hq' : $data = $db_multimedia->GetAllHardQuestions($lbegin,$LISTING_LIMIT);
- $headertitle = $S_ALL." ".$S_HARD_QUESTIONS;
- $linktext = "&listtype=hq&type=audio";
- $scount = $db_multimedia->GetHardQuestionsCount();
- break;
- case 'cat' : $data = $db_multimedia->GetMultimediaAudioCategory($cat);
- $headertitle = $data[0]->Category;
- $scount = count($data);
- $linktext = "&cat=".$cat."&type=audio";
- break;
- }
- $smarty->assign('heading',$headertitle." (".$scount." ".$S_TOTAL.")");
- $listelements = array();
- foreach ($data as $value) {
- $imageicons = array();
- $filesize = "";
- $newtext = "";
- if($value->ALinkStream) {
- $imageicons[] = array('Link'=>$value->ALinkStream,
- 'src'=>$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.$MULTIMEDIA_AUDIO_IMG,'alt'=>$value->Title);
- }
- if($value->ALinkDownload) {
- $imageicons[] = array('Link'=>$value->ALinkDownload,
- 'src'=>$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.$MULTIMEDIA_AUDIO_IMG_DL,'alt'=>$value->Title);
- }
- if($value->Transcript != "") {
- $imageicons[] = array('Link'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.$MULTIMEDIA_FILE.
- "?id=".$value->ID."&type=audio&trans=yes",
- 'src'=>$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.$MULTIMEDIA_TRANS_IMG,'alt'=>$S_TRANSCRIPT);
- if($SHOW_PDF_DL) {
- $imageicons[] = array('Link'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.$MULTIMEDIA_FILE.
- "?id=".$value->ID."&type=audio&dlpdf=yes",
- 'src'=>$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.$PDF_IMG,'alt'=>"PDF");
- }
- }
- if($SHOW_FILESIZE_IN_LIST && $value->ALinkDownload) {
- $filesize .= "<span class=\"filesize\">";
- $filesize .= " (".UtilFiles::GetFilesize($value->ALinkDownload).")";
- $filesize .= "</span>";
- }
- if(isset($newarr[$value->ID])) { $newtext = " [".$S_NEW."]"; }
- $listelements[] = array('LinkPath'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.$MULTIMEDIA_FILE."?type=audio&id=".$value->ID,
- 'Title'=>$value->Title,'ImageIcons'=>$imageicons,'SubTitle'=>$filesize." ".$newtext);
- }
- $smarty->assign('listelements',$listelements);
- $bottomlinks = array();
- if($scount >= $lbegin-$LISTING_LIMIT && $lbegin-$LISTING_LIMIT >= 0) {
- $bottomlinks[] = array(
- 'LinkPath'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.$MULTIMEDIA_FILE."?"."lbegin=".
- ($lbegin-$LISTING_LIMIT)."&scount=".$scount.$linktext,
- 'LinkText'=>"<< ".$S_PREVIOUS." ".$LISTING_LIMIT." ".$S_RESULTS);
- }
- if($lbegin+$LISTING_LIMIT < $scount) {
- if($scount-($lbegin+$LISTING_LIMIT) < $LISTING_LIMIT) {
- $linktext = $S_NEXT." ".($scount-($lbegin+$LISTING_LIMIT))." ".$S_RESULTS." >>";
- }
- else { $linktext = $S_NEXT." ".$LISTING_LIMIT." ".$S_RESULTS." >>"; }
- $bottomlinks[] = array(
- 'LinkPath'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.$MULTIMEDIA_FILE."?"."lbegin=".
- ($lbegin+$LISTING_LIMIT).$linktext."&scount=".$scount,
- 'LinkText'=>$linktext);
- }
- $smarty->assign('bottomlinks',$bottomlinks);
- }
- }
-
- else if($type == "video") {
- if($listtype != null) {
- switch($listtype) {
- case 'all' : $data = $db_multimedia->GetMultimediaVideo();
- $headertitle = $S_ALL." ".$S_VIDEO." ".$S_MULTIMEDIA;
- break;
- case 'cat' : $data = $db_multimedia->GetMultimediaVideoCategory($cat);
- $headertitle = $data[0]->Category;
- break;
- }
- $smarty->assign('heading',$headertitle." (".count($data)." ".$S_TOTAL.")");
- $listelements = array();
- foreach ($data as $value) {
- $listelements[] = array(
- 'LinkPath'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.$MULTIMEDIA_FILE."?type=video&id=".$value->ID,
- 'Title'=>$value->Title,
- 'ImageIcons'=>array(array(
- 'LinkPath'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.$MULTIMEDIA_FILE."?type=video&id=".$value->ID,
- 'src'=>$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.$MULTIMEDIA_VIDEO_IMG,
- 'alt'=>$value->Title)));
- }
- $smarty->assign('listelements',$listelements);
- }
-
- else if($id != null) {
- $value =& $db_multimedia->GetMultimediaVideoItem($id);
- $tblarr = array();
- $tblclass = "tbl-listing";
- $tbltdclass = array("tbl-listing-title","tbl-listing-item");
- $tblheader = "<h2>".$value->Title." <img border=\"0\" align=".
- "\"middle\" src=\"".$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.
- $MULTIMEDIA_VIDEO_IMG."\" alt=\"".$S_VIDEO."\" border=\"0\" \>"."</h2>";
-
- array_push($tblarr,array($S_CATEGORY,$value->Category));
-
- if($value->Links != null) {
- foreach($value->Links as $linkkey => $linkvalue) {
- $filesize = UtilFiles::GetFilesize($linkvalue);
- $filesizebytes = UtilFiles::GetFilesize($linkvalue,1);
- $linkstring = "<a href=\"".$linkvalue."\">".$S_WATCH."</a> ".
- " <span class=\"filesize\">"."(".$filesize.")".
- "<br />[".$S_DOWNLOAD." ".$S_TIME.": ".round(round($filesizebytes/$MODEM_TRANSFER_RATE)/60).
- " ".$S_MIN.", ".$S_MODEM.". ".round(round($filesizebytes/$BROADBAND_TRANSFER_RATE)/60).
- " ".$S_MIN.", ".$S_BROADBAND."]</span>";
- array_push($tblarr,array($linkkey,$linkstring));
- }
- }
-
- if ($value->Description != null) {
- array_push($tblarr,array($S_DESC,stripslashes($value->Description)));
- }
- if ($value->Notes != null) {
- array_push($tblarr,array($S_NOTES,stripslashes($value->Notes)));
- }
- $smarty->assign('printtable',UtilHtml::createTable($tblarr,$tblheader,$tblclass,"","",$tbltdclass));
- }
- }
- }
-
- else {
- $data = $db_multimedia->GetMultimediaAudioRecent($NUM_FILES_SHOW_MAIN);
- $vdata = $db_multimedia->GetMultimediaVideoRecent($NUM_FILES_SHOW_MAIN);
-
- if($data == null && $vdata == null) {
- $smarty->assign('heading',$S_MULTIMEDIA);
- $smarty->assign('notice',$N_MULTIMEDIA_NONE);
- }
- else {
- $listelementsarr = array();
- $bottomlinks = array();
- if($data != null) {
- $listsection = array();
- $listsection['heading'] = count($data).$MULTIMEDIA_AUDIO_HEADING;
- $listsection['List'] = array();
- foreach ($data as $value) {
- $imageicons = array();
- if($value->ALinkStream) {
- $imageicons[] = array('Link'=>$value->ALinkStream,
- 'src'=>$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.$MULTIMEDIA_AUDIO_IMG,'alt'=>$value->Title);
- }
- if($value->ALinkDownload) {
- $imageicons[] = array('Link'=>$value->ALinkDownload,
- 'src'=>$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.$MULTIMEDIA_AUDIO_IMG_DL,'alt'=>$value->Title);
- }
- $listsection['List'][] = array(
- 'LinkPath'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.$MULTIMEDIA_FILE."?type=audio&id=".$value->ID,
- 'Title'=>$value->Title,'ImageIcons'=>$imageicons);
- }
- $listelementsarr[] = $listsection;
- $bottomlinks[] = array('LinkPath'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.$MULTIMEDIA_FILE.
- "?listtype=all&type=audio",
- 'LinkText'=>$S_ALL." ".$S_AUDIO." ".$S_FILES);
- }
-
- if($vdata != null) {
- $listsection = array();
- $listsection['heading'] = count($vdata).$MULTIMEDIA_VIDEO_HEADING;
- $listsection['List'] = array();
- foreach ($vdata as $value) {
- $listsection['List'][] = array(
- 'LinkPath'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.$MULTIMEDIA_FILE."?type=video&id=".$value->ID,
- 'Title'=>$value->Title,
- 'ImageIcons'=>array(array(
- 'Link'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.$MULTIMEDIA_FILE."?type=video&id=".$value->ID,
- 'src'=>$HTTP_DOCUMENT_ROOT.$IMAGE_PATH.$MULTIMEDIA_VIDEO_IMG,
- 'alt'=>$value->Title)));
- }
- $listelementsarr[] = $listsection;
- $bottomlinks[] = array('LinkPath'=>$HTTP_DOCUMENT_ROOT.$MULTIMEDIA_DIR.$MULTIMEDIA_FILE.
- "?listtype=all&type=video",
- 'LinkText'=>$S_ALL." ".$S_VIDEO." ".$S_FILES);
- }
- $smarty->assign('listelementsarr',$listelementsarr);
- }
- }
- $smarty->assign('bottomnote',$S_NOTE_MULTIMEDIA);
- UtilSmarty::displaySectionPage($smarty);
- ?>
- <?php require_once $SERVER_DIRECTORY.$INCLUDE_PATH.$FOOTER; ?>