📄 media.htm
字号:
<HTML>
<HEAD>
<TITLE>媒体文件属性</TITLE>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<style type="text/css">
body, a, table, div, span, td, th, input, select{font:9pt;font-family: "宋体", Verdana, Arial, Helvetica, sans-serif;}
body {padding:5px}
</style>
<script language="JavaScript" src="dialog.js"></script>
<script language="JavaScript">
// 文件来源单选点击事件
function RadioClick(what){
if (what=="url"){
d_checkfromfile.checked=false;
d_fromurl.disabled=false;
d_checkfromurl.checked=true;
d_file.myform.uploadfile.disabled=true;
}else{
d_checkfromurl.checked=false;
d_file.myform.uploadfile.disabled=false;
d_checkfromfile.checked=true;
d_fromurl.disabled=true;
}
}
// 上传帧调入完成时执行
function UploadLoaded(){
// 初始radio
RadioClick('file');
}
// 上传错误
function UploadError(sErrDesc){
AbleItems();
RadioClick('file');
divProcessing.style.display="none";
try {
BaseAlert(d_file.myform.uploadfile,sErrDesc);
}
catch(e){}
}
// 文件上传完成时执行,带入上传文件名
function UploadSaved(sPathFileName){
d_fromurl.value = sPathFileName;
ReturnValue();
}
// 本窗口返回值
function ReturnValue(){
var sFromUrl = d_fromurl.value;
var sWidth = d_width.value;
var sHeight = d_height.value;
var sHTML = '<EMBED src="' + sFromUrl + '" width="' + sWidth + '" height="' + sHeight + '" type="audio/x-pn-realaudio-plugin" autostart="true" controls="IMAGEWINDOW,ControlPanel,StatusBar" console="Clip1"></EMBED>';
dialogArguments.insertHTML(sHTML);
window.returnValue = null;
window.close();
}
// 点确定时执行
function ok(){
// 数字型输入的有效性
d_width.value=ToInt(d_width.value);
d_height.value=ToInt(d_height.value);
if (d_checkfromurl.checked){
// 返回值
ReturnValue();
}else{
// 上传文件判断
if (!d_file.CheckUploadForm()) return false;
// 使各输入框无效
DisableItems();
// 显示正在上传文件
divProcessing.style.display="";
// 上传表单提交
d_file.myform.submit();
}
}
// 使所有输入框无效
function DisableItems(){
d_checkfromfile.disabled=true;
d_checkfromurl.disabled=true;
d_fromurl.disabled=true;
d_width.disabled=true;
d_height.disabled=true;
Ok.disabled=true;
}
// 使所有输入框有效
function AbleItems(){
d_checkfromfile.disabled=false;
d_checkfromurl.disabled=false;
d_fromurl.disabled=false;
d_width.disabled=false;
d_height.disabled=false;
Ok.disabled=false;
}
</script>
</HEAD>
<BODY bgColor=menu>
<table border=0 cellpadding=0 cellspacing=0 align=center>
<tr>
<td>
<fieldset>
<legend>媒体文件来源</legend>
<table border=0 cellpadding=0 cellspacing=0>
<tr><td colspan=9 height=5></td></tr>
<tr>
<td width=7></td>
<td width=54 align=right onclick="RadioClick('file')"><input type=radio id="d_checkfromfile" value="1" onclick="RadioClick('file')">上传:</td>
<td width=5></td>
<td colspan=5>
<Script Language=JavaScript>
document.write('<iframe id=d_file frameborder=0 src="../upload.asp?type=media&style=' + config.StyleName + '" width="100%" height="22" scrolling=no></iframe>');
</Script>
</td>
<td width=7></td>
</tr>
<tr><td colspan=9 height=5></td></tr>
<tr>
<td width=7></td>
<td width=54 align=right onclick="RadioClick('url')"><input type=radio id="d_checkfromurl" value="1" onclick="RadioClick('url')">网络:</td>
<td width=5></td>
<td colspan=5><input type=text id="d_fromurl" style="width:243px" size=30 value="http://"></td>
<td width=7></td>
</tr>
<tr><td colspan=9 height=5></td></tr>
</table>
</fieldset>
</td>
</tr>
<tr><td height=5></td></tr>
<tr>
<td>
<fieldset>
<legend>播放效果</legend>
<table border=0 cellpadding=0 cellspacing=0>
<tr><td colspan=9 height=5></td></tr>
<tr>
<td width=7></td>
<td noWrap>播放宽度:</td>
<td width=5></td>
<td><input type=text id=d_width size=10 value="200" ONKEYPRESS="event.returnValue=IsDigit();" maxlength=4></td>
<td width=40></td>
<td noWrap>播放高度:</td>
<td width=5></td>
<td><input type=text id=d_height size=10 value="200" ONKEYPRESS="event.returnValue=IsDigit();" maxlength=4></td>
<td width=7></td>
</tr>
<tr><td colspan=9 height=5></td></tr>
</table>
</fieldset>
</td>
</tr>
<tr><td height=5></td></tr>
<tr><td align=right><input type=submit value=' 确定 ' id=Ok onclick="ok()"> <input type=button value=' 取消 ' onclick="window.close();"></td></tr>
</table>
<div id=divProcessing style="width:200px;height:30px;position:absolute;left:70px;top:50px;display:none">
<table border=0 cellpadding=0 cellspacing=1 bgcolor="#000000" width="100%" height="100%"><tr><td bgcolor=#3A6EA5><marquee align="middle" behavior="alternate" scrollamount="5"><font color=#FFFFFF>...文件上传中...请等待...</font></marquee></td></tr></table>
</div>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -