function poodll_callback($link) { global $CFG, $COURSE, $USER; //get our filter props //we use a function in the poodll poodllresourcelib, because //parsing will also need to be done by the html editor $filterprops = fetch_filter_properties($link[0]); //if we have no props, quit if (empty($filterprops)) { return ""; } //if we want to ignore the filter (for "how to use a filter" demos) we let it go //to use this, make the last parameter of the filter passthrough=1 if (!empty($filterprops['passthrough'])) { return str_replace(",passthrough=1", "", $link[0]); } //Init our return variable $returnHtml = ""; //depending on the type of filter switch ($filterprops['type']) { case 'video': //$returnHtml="<BR />" . fetchSimpleVideoPlayer($filterprops['path'],$filterprops['width'],$filterprops['height']); $returnHtml = "<BR />" . fetchSimpleVideoPlayer($filterprops['path'], !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_videowidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_videoheight, !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'rtmp', !empty($filterprops['embed']) ? $filterprops['embed'] == 'true' : false, !empty($filterprops['permitfullscreen']) ? $filterprops['permitfullscreen'] : false, !empty($filterprops['embedstring']) ? $filterprops['embedstring'] : 'Play'); break; case 'wmvvideo': $returnHtml = "<BR />" . fetchWMVPlayer($filterprops['path'], !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_videowidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_videoheight); break; case 'audio': $returnHtml = "<BR />" . fetchSimpleAudioPlayer($filterprops['path'], !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'rtmp', !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_audiowidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_audioheight, !empty($filterprops['embed']) ? $filterprops['embed'] == 'true' : false, !empty($filterprops['embedstring']) ? $filterprops['embedstring'] : 'Play'); break; case 'audiolist': $returnHtml = "<BR />" . fetchAudioListPlayer($filterprops['path'], !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'rtmp', !empty($filterprops['width']) ? $filterprops['width'] : 400, !empty($filterprops['height']) ? $filterprops['height'] : 250, !empty($filterprops['sequentialplay']) ? $filterprops['sequentialplay'] : 'true'); break; case 'audiotest': $returnHtml = "<BR />" . fetchAudioTestPlayer($filterprops['path'], !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'rtmp', !empty($filterprops['width']) ? $filterprops['width'] : 400, !empty($filterprops['height']) ? $filterprops['height'] : 50); break; case 'talkback': $returnHtml = "<BR />" . fetchTalkbackPlayer($filterprops['path'], !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'rtmp', !empty($filterprops['recordable']) ? $filterprops['recordable'] : 'false', !empty($filterprops['savefolder']) ? $filterprops['savefolder'] : 'default'); break; case 'bigvideogallery': $returnHtml = "<BR />" . fetchBigVideoGallery($filterprops['path'], !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'rtmp', !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_biggallwidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_biggallheight); break; case 'videorecorder': $returnHtml = "<BR />" . fetchSimpleVideoRecorder($filterprops['savefolder']); break; case 'audiorecorder': $returnHtml = "<BR />" . fetchSimpleAudioRecorder($filterprops['savefolder']); break; case 'calculator': $returnHtml = "<BR />" . fetch_poodllcalc(!empty($filterprops['width']) ? $filterprops['width'] : 300, !empty($filterprops['height']) ? $filterprops['height'] : 400); break; case 'teachersrecorder': $returnHtml = "<BR />" . fetch_teachersrecorder($filterprops['savepath'], ""); break; case 'adminconsole': $returnHtml = "<BR />" . fetch_poodllconsole("", "billybob", -1, true); break; case 'countdown': $returnHtml = "<BR />" . fetch_countdowntimer($filterprops['initseconds'], !empty($filterprops['usepresets']) ? $filterprops['usepresets'] : 'false', !empty($filterprops['width']) ? $filterprops['width'] : 400, !empty($filterprops['height']) ? $filterprops['height'] : 265, !empty($filterprops['fontsize']) ? $filterprops['fontsize'] : 64, !empty($filterprops['mode']) ? $filterprops['mode'] : 'normal', !empty($filterprops['permitfullscreen']) ? $filterprops['permitfullscreen'] : false, !empty($filterprops['uniquename']) ? $filterprops['uniquename'] : 'auniquename'); break; case 'counter': $returnHtml = "<BR />" . fetch_counter(!empty($filterprops['initcount']) ? $filterprops['initcount'] : 0, !empty($filterprops['usepresets']) ? $filterprops['usepresets'] : 'false', !empty($filterprops['width']) ? $filterprops['width'] : 480, !empty($filterprops['height']) ? $filterprops['height'] : 265, !empty($filterprops['fontsize']) ? $filterprops['fontsize'] : 64, !empty($filterprops['permitfullscreen']) ? $filterprops['permitfullscreen'] : false); break; case 'dice': $returnHtml = "<BR />" . fetch_dice(!empty($filterprops['dicecount']) ? $filterprops['dicecount'] : 1, !empty($filterprops['dicesize']) ? $filterprops['dicesize'] : 200, !empty($filterprops['width']) ? $filterprops['width'] : 300, !empty($filterprops['height']) ? $filterprops['height'] : 300); break; case 'flashcards': $returnHtml = "<BR />" . fetch_flashcards($filterprops['cardset'], !empty($filterprops['cardwidth']) ? $filterprops['cardwidth'] : 300, !empty($filterprops['cardheight']) ? $filterprops['cardheight'] : 150, !empty($filterprops['randomize']) ? $filterprops['randomize'] : 'yes', !empty($filterprops['width']) ? $filterprops['width'] : 400, !empty($filterprops['height']) ? $filterprops['height'] : 300); break; case 'stopwatch': $returnHtml = "<BR />" . fetch_stopwatch(!empty($filterprops['width']) ? $filterprops['width'] : 400, !empty($filterprops['height']) ? $filterprops['height'] : 265, !empty($filterprops['fontsize']) ? $filterprops['fontsize'] : 64, !empty($filterprops['mode']) ? $filterprops['mode'] : 'normal', !empty($filterprops['permitfullscreen']) ? $filterprops['permitfullscreen'] : false, !empty($filterprops['uniquename']) ? $filterprops['uniquename'] : 'auniquename'); break; case 'smallvideogallery': $returnHtml = "<BR />" . fetchSmallVideoGallery($filterprops['path'], !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'rtmp', !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_smallgallwidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_smallgallheight, !empty($filterprops['permitfullscreen']) ? $filterprops['permitfullscreen'] : false); break; case 'newpoodllpairwork': $returnHtml = "<BR />" . fetch_embeddablepairclient(!empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_newpairwidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_newpairheight, !empty($filterprops['chat']) ? $filterprops['chat'] : true, !empty($filterprops['whiteboard']) ? $filterprops['whiteboard'] : false, !empty($filterprops['showvideo']) ? $filterprops['showvideo'] : false, !empty($filterprops['whiteboardback']) ? $filterprops['whiteboardback'] : ''); break; case 'screensubscribe': $returnHtml = "<BR />" . fetch_screencast_subscribe("", true, !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_showwidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_showheight); break; case 'poodllpalette': $returnHtml = "<BR />" . fetch_poodllpalette($filterprops['width'], $filterprops['height']); break; case 'whiteboard': $returnHtml = "<BR />" . fetch_whiteboard(!empty($filterprops['boardname']) ? $filterprops['boardname'] : "whiteboard", !empty($filterprops['backimage']) ? $filterprops['backimage'] : "", !empty($filterprops['slave']) && $filterprops['slave'] == 'true' ? $filterprops['slave'] : false, !empty($filterprops['rooms']) ? $filterprops['rooms'] : "", !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_whiteboardwidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_whiteboardheight, !empty($filterprops['mode']) ? $filterprops['mode'] : 'normal', !empty($filterprops['standalone']) && $filterprops['standalone'] == 'true' ? $filterprops['standalone'] : 'false'); break; case 'poodllpairwork': $courseid = $COURSE->id; $username = $USER->username; $poodllpairworkplayer = ""; $studentalias = ""; $pairmap = ""; if ($pairmap = get_record("poodllpairwork_usermap", "username", $username, "course", $courseid)) { $studentalias = $pairmap->role; } //if we have a role and hence a session. if ($studentalias != "") { $me = get_record('user', 'username', $username); $partner = get_record('user', 'username', $pairmap->partnername); $partnerpic = fetch_user_picture($partner, 35); $mepic = fetch_user_picture($me, 35); $poodllpairworkplayer = "<h4>" . get_string("yourpartneris", "poodllpairwork") . fullname($partner) . "</h4>"; $poodllpairworkplayer .= fetchPairworkPlayer($pairmap->username, $pairmap->partnername, $mepic, fullname($me), $partnerpic, fullname($partner)); } $returnHtml = "<BR />" . $poodllpairworkplayer; break; default: } //return our html return $returnHtml; }
function filter_poodll_callback(array $link) { global $CFG, $COURSE, $USER; ///$PAGE->requires->js_init_call('M.filter_poodll.init', array()); //get our filter props //we use a function in the poodll poodllresourcelib, because //parsing will also need to be done by the html editor $filterprops = fetch_filter_properties($link[0]); //if we have no props, quit if (empty($filterprops)) { return ""; } //if we want to ignore the filter (for "how to use a filter" demos) we let it go //to use this, make the last parameter of the filter passthrough=1 if (!empty($filterprops['passthrough'])) { return str_replace(",passthrough=1", "", $link[0]); } //Init our return variable $returnHtml = ""; //Runtime JS or Flash if (empty($filterprops['runtime'])) { $filterprops['runtime'] = 'auto'; } //depending on the type of filter switch ($filterprops['type']) { case 'adminconsole': $returnHtml = fetch_poodllconsole($filterprops['runtime']); break; case 'audio': $returnHtml = fetchSimpleAudioPlayer($filterprops['runtime'], $filterprops['path'], !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'rtmp', !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_audiowidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_audioheight, !empty($filterprops['embed']) ? $filterprops['embed'] == 'true' : false, !empty($filterprops['embedstring']) ? $filterprops['embedstring'] : 'Play', false, !empty($filterprops['usepoodlldata']) ? $filterprops['usepoodlldata'] == 'true' : false, !empty($filterprops['splashurl']) ? $filterprops['splashurl'] : ''); break; case 'audiolist': $returnHtml = fetchAudioListPlayer($filterprops['runtime'], $filterprops['path'], !empty($filterprops['filearea']) ? $filterprops['filearea'] : 'content', !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'rtmp', !empty($filterprops['width']) ? $filterprops['width'] : 400, !empty($filterprops['height']) ? $filterprops['height'] : 250, !empty($filterprops['sequentialplay']) ? $filterprops['sequentialplay'] : 'true', !empty($filterprops['player']) ? $filterprops['player'] : $CFG->filter_poodll_defaultplayer, !empty($filterprops['showplaylist']) ? $filterprops['showplaylist'] == 'true' : true, !empty($filterprops['usepoodlldata']) ? $filterprops['usepoodlldata'] == 'true' : false); break; case 'audiorecorder': $returnHtml = fetchSimpleAudioRecorder($filterprops['runtime'], !empty($filterprops['savefolder']) ? $filterprops['savefolder'] : ''); break; case 'audiotest': $returnHtml = fetchAudioTestPlayer($filterprops['runtime'], $filterprops['path'], !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'rtmp', !empty($filterprops['width']) ? $filterprops['width'] : 400, !empty($filterprops['height']) ? $filterprops['height'] : 50, !empty($filterprops['filearea']) ? $filterprops['filearea'] : 'content', !empty($filterprops['usepoodlldata']) ? $filterprops['usepoodlldata'] == 'true' : false); break; case 'talkback': $returnHtml = fetchTalkbackPlayer($filterprops['runtime'], $filterprops['path'], !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'rtmp', !empty($filterprops['recordable']) ? $filterprops['recordable'] : 'false', !empty($filterprops['savefolder']) ? $filterprops['savefolder'] : 'default'); break; case 'bigvideogallery': $returnHtml = fetchBigVideoGallery($filterprops['runtime'], $filterprops['path'], !empty($filterprops['filearea']) ? $filterprops['filearea'] : 'content', !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'http', !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_biggallwidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_biggallheight, !empty($filterprops['usepoodlldata']) ? $filterprops['usepoodlldata'] == 'true' : false); break; case 'calculator': $returnHtml = fetch_poodllcalc($filterprops['runtime'], !empty($filterprops['width']) ? $filterprops['width'] : 300, !empty($filterprops['height']) ? $filterprops['height'] : 400, !empty($filterprops['size']) ? $filterprops['size'] : 'normal'); break; case 'cambroadcaster': $returnHtml = fetchCamBroadcaster($filterprops['runtime'], !empty($filterprops['mename']) ? $filterprops['mename'] : '', !empty($filterprops['broadcastkey']) ? $filterprops['broadcastkey'] : '1234567'); break; case 'countdown': $returnHtml = fetch_countdowntimer($filterprops['runtime'], $filterprops['initseconds'], !empty($filterprops['usepresets']) ? $filterprops['usepresets'] : 'false', !empty($filterprops['width']) ? $filterprops['width'] : 400, !empty($filterprops['height']) ? $filterprops['height'] : 300, !empty($filterprops['fontheight']) ? $filterprops['fontheight'] : 64, !empty($filterprops['mode']) ? $filterprops['mode'] : 'normal', !empty($filterprops['permitfullscreen']) ? $filterprops['permitfullscreen'] : false, !empty($filterprops['uniquename']) ? $filterprops['uniquename'] : 'auniquename'); break; case 'counter': $returnHtml = fetch_counter($filterprops['runtime'], !empty($filterprops['initcount']) ? $filterprops['initcount'] : 0, !empty($filterprops['usepresets']) ? $filterprops['usepresets'] : 'false', !empty($filterprops['width']) ? $filterprops['width'] : 480, !empty($filterprops['height']) ? $filterprops['height'] : 265, !empty($filterprops['fontheight']) ? $filterprops['fontheight'] : 64, !empty($filterprops['permitfullscreen']) ? $filterprops['permitfullscreen'] : false); break; case 'dice': $returnHtml = fetch_dice($filterprops['runtime'], !empty($filterprops['dicecount']) ? $filterprops['dicecount'] : 1, !empty($filterprops['dicesize']) ? $filterprops['dicesize'] : 200, !empty($filterprops['width']) ? $filterprops['width'] : 600, !empty($filterprops['height']) ? $filterprops['height'] : 300); break; case 'explorer': $returnHtml = fetch_explorer($filterprops['runtime'], !empty($filterprops['width']) ? $filterprops['width'] : 1250, !empty($filterprops['height']) ? $filterprops['height'] : 800, !empty($filterprops['moduleid']) ? $filterprops['moduleid'] : ''); break; case 'flashcards': $returnHtml = fetch_flashcards($filterprops['runtime'], !empty($filterprops['cardset']) ? $filterprops['cardset'] : -1, !empty($filterprops['qname']) ? $filterprops['qname'] : "", !empty($filterprops['frontcolor']) ? $filterprops['frontcolor'] : "0xDDDDDD", !empty($filterprops['backcolor']) ? $filterprops['backcolor'] : "0x000000", !empty($filterprops['cardwidth']) ? $filterprops['cardwidth'] : 300, !empty($filterprops['cardheight']) ? $filterprops['cardheight'] : 150, !empty($filterprops['randomize']) ? $filterprops['randomize'] : 'yes', !empty($filterprops['width']) ? $filterprops['width'] : 400, !empty($filterprops['height']) ? $filterprops['height'] : 300); break; case 'miniplayer': $returnHtml = fetch_miniplayer($filterprops['runtime'], $filterprops['url'], !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'http', !empty($filterprops['imageurl']) ? $filterprops['imageurl'] : '', !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_miniplayerwidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_miniplayerwidth, !empty($filterprops['iframe']) ? $filterprops['iframe'] == 'true' : false); break; case 'onceplayer': $returnHtml = fetch_onceplayer($filterprops['runtime'], $filterprops['url'], !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'http', !empty($filterprops['width']) ? $filterprops['width'] : 0, !empty($filterprops['height']) ? $filterprops['height'] : 0, !empty($filterprops['iframe']) ? $filterprops['iframe'] == 'true' : false); break; case 'newpoodllpairwork': $returnHtml = fetch_embeddablepairclient($filterprops['runtime'], !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_newpairwidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_newpairheight, !empty($filterprops['chat']) ? $filterprops['chat'] : true, !empty($filterprops['whiteboard']) ? $filterprops['whiteboard'] : false, !empty($filterprops['showvideo']) ? $filterprops['showvideo'] : false, !empty($filterprops['whiteboardback']) ? $filterprops['whiteboardback'] : ''); break; case 'stopwatch': $returnHtml = fetch_stopwatch($filterprops['runtime'], !empty($filterprops['width']) ? $filterprops['width'] : 400, !empty($filterprops['height']) ? $filterprops['height'] : 265, !empty($filterprops['fontheight']) ? $filterprops['fontheight'] : 64, !empty($filterprops['mode']) ? $filterprops['mode'] : 'normal', !empty($filterprops['permitfullscreen']) ? $filterprops['permitfullscreen'] : false, !empty($filterprops['uniquename']) ? $filterprops['uniquename'] : 'auniquename'); break; case 'smallvideogallery': $returnHtml = fetchSmallVideoGallery($filterprops['runtime'], $filterprops['path'], !empty($filterprops['filearea']) ? $filterprops['filearea'] : 'content', !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'http', !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_smallgallwidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_smallgallheight, !empty($filterprops['permitfullscreen']) ? $filterprops['permitfullscreen'] : false, !empty($filterprops['usepoodlldata']) ? $filterprops['usepoodlldata'] == 'true' : false); break; case 'screensubscribe': $returnHtml = fetch_screencast_subscribe($filterprops['runtime'], !empty($filterprops['mename']) ? $filterprops['mename'] : '', true, !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_showwidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_showheight, !empty($filterprops['broadcastkey']) ? $filterprops['broadcastkey'] : '1234567'); break; case 'poodllpalette': $returnHtml = fetch_poodllpalette($filterprops['runtime'], $filterprops['width'], $filterprops['height'], "swf"); break; case 'wordplayer': $returnHtml = fetch_wordplayer($filterprops['runtime'], $filterprops['url'], $filterprops['word'], !empty($filterprops['fontsize']) ? $filterprops['fontsize'] : $CFG->filter_poodll_wordplayerfontsize, !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'http', !empty($filterprops['width']) ? $filterprops['width'] : "0", !empty($filterprops['height']) ? $filterprops['height'] : "0", !empty($filterprops['iframe']) ? $filterprops['iframe'] == 'true' : false); break; case 'whiteboard': $returnHtml = fetch_whiteboard($filterprops['runtime'], !empty($filterprops['boardname']) ? $filterprops['boardname'] : "whiteboard", !empty($filterprops['backimage']) ? $filterprops['backimage'] : "", !empty($filterprops['slave']) && $filterprops['slave'] == 'true' ? $filterprops['slave'] : false, !empty($filterprops['rooms']) ? $filterprops['rooms'] : "", !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_whiteboardwidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_whiteboardheight, !empty($filterprops['mode']) ? $filterprops['mode'] : 'normal', !empty($filterprops['standalone']) && $filterprops['standalone'] == 'true' ? $filterprops['standalone'] : 'false'); break; case 'poodllpairwork': $courseid = $COURSE->id; $username = $USER->username; $poodllpairworkplayer = ""; $studentalias = ""; $pairmap = ""; if ($pairmap = get_record("poodllpairwork_usermap", "username", $username, "course", $courseid)) { $studentalias = $pairmap->role; } //if we have a role and hence a session. if ($studentalias != "") { $me = get_record('user', 'username', $username); $partner = get_record('user', 'username', $pairmap->partnername); $partnerpic = fetch_user_picture($partner, 35); $mepic = fetch_user_picture($me, 35); $poodllpairworkplayer = "<h4>" . get_string("yourpartneris", "poodllpairwork") . fullname($partner) . "</h4>"; $poodllpairworkplayer .= fetchPairworkPlayer($pairmap->username, $pairmap->partnername, $mepic, fullname($me), $partnerpic, fullname($partner)); } $returnHtml = $poodllpairworkplayer; break; case 'quizlet': $returnHtml = fetch_quizlet($filterprops['id'], !empty($filterprops['title']) ? $filterprops['title'] : 'quizlet', !empty($filterprops['mode']) ? $filterprops['mode'] : 'familiarize', !empty($filterprops['width']) ? $filterprops['width'] : '100%', !empty($filterprops['height']) ? $filterprops['height'] : '310'); break; case 'scrollerstart': $returnHtml = fetch_poodllscroller(true, !empty($filterprops['width']) ? $filterprops['width'] : '400', !empty($filterprops['height']) ? $filterprops['height'] : '200', !empty($filterprops['speed']) ? $filterprops['speed'] : '10', !empty($filterprops['repeat']) ? $filterprops['repeat'] : 'yes', !empty($filterprops['axis']) ? $filterprops['axis'] : 'y', !empty($filterprops['pixelshift']) ? $filterprops['pixelshift'] : '2'); break; case 'scrollerstop': $returnHtml = fetch_poodllscroller(false); break; case 'sliderocket': $returnHtml = fetch_sliderocket($filterprops['id'], !empty($filterprops['width']) ? $filterprops['width'] : '400', !empty($filterprops['height']) ? $filterprops['height'] : '326'); break; case 'snapshot': $returnHtml = fetchSnapshotCamera(!empty($filterprops['updatecontrol']) ? $filterprops['updatecontrol'] : 'filename', !empty($filterprops['filename']) ? $filterprops['filename'] : 'filename', !empty($filterprops['width']) ? $filterprops['width'] : '350', !empty($filterprops['height']) ? $filterprops['height'] : '400'); break; case 'teachersrecorder': $returnHtml = fetch_teachersrecorder($filterprops['runtime'], $filterprops['savepath'], ""); break; case 'videorecorder': $returnHtml = fetchSimpleVideoRecorder($filterprops['runtime'], !empty($filterprops['savefolder']) ? $filterprops['savefolder'] : ''); break; case 'video': //$returnHtml= fetchSimpleVideoPlayer($filterprops['path'],$filterprops['width'],$filterprops['height']); $returnHtml = fetchSimpleVideoPlayer($filterprops['runtime'], $filterprops['path'], !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_videowidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_videoheight, !empty($filterprops['protocol']) ? $filterprops['protocol'] : 'rtmp', !empty($filterprops['embed']) ? $filterprops['embed'] == 'true' : false, !empty($filterprops['permitfullscreen']) ? $filterprops['permitfullscreen'] : false, !empty($filterprops['embedstring']) ? $filterprops['embedstring'] : 'Play', !empty($filterprops['splashurl']) ? $filterprops['splashurl'] : ''); break; case 'wmvvideo': $returnHtml = fetchWMVPlayer($filterprops['runtime'], $filterprops['path'], !empty($filterprops['width']) ? $filterprops['width'] : $CFG->filter_poodll_videowidth, !empty($filterprops['height']) ? $filterprops['height'] : $CFG->filter_poodll_videoheight); break; default: } //return our html return $returnHtml; }