13 require_once
'HTML/QuickForm/file.php';
29 if ( isset($elementName) ){
31 parent::HTML_QuickForm_file($elementName, $elementLabel, $attributes);
38 $field =& $this->getFieldDef();
41 $ID =
'temp'.rand(1,1000000);
42 if ( $this->record and $this->record->getValue(
'id') ){
43 $ID = $this->record->getValue(
'id');
48 $ray_dir =
"http://".$_SERVER[
'HTTP_HOST'].dirname(
$_SERVER[
'SCRIPT_NAME']);
49 if ( $ray_dir{strlen($ray_dir)-1} !=
'/' ) $ray_dir .=
'/';
50 $ray_xml = $ray_dir.
"get_xml.php";
53 <div
class=
"help">If you have a web camera you can press the <em>Record</em> button below to record your piece. <a href=
"troubleshooting.php">Troubleshooting instructions</a>.</div>
54 <
object classid=
"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase=
"http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0" width=
"348" height=
"248" id=
"ray_recorder" align=
"middle">
55 <param name=
"allowScriptAccess" value=
"always" />
56 <param name=
"movie" value=
"{$ray_dir}ray_recorder.swf" />
57 <param name=
"quality" value=
"high" />
58 <param name=
"wmode" value=
"TRANSPARENT" />
59 <param name=
"FlashVars" value=
"ID={$ID}&url={$ray_xml}" />
61 src=
"{$ray_dir}ray_recorder.swf"
65 width=
"348" height=
"248"
68 allowScriptAccess=
"always"
69 type=
"application/x-shockwave-flash"
70 FlashVars=
"ID={$ID}&url={$ray_xml}"
71 pluginspage=
"http://www.macromedia.com/go/getflashplayer" />
73 <div
class=
"help">Or upload a movie file from your camera, phone, or computer...</div>
74 <input name=
"{$this->getName()}__webcam__" type=
"hidden" value=
"{$value}" />