首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网站开发 > asp.net >

求解,帮小弟我把ASP代码翻译成ASP.NET关键在前面<%%>里面,后面只是调用播放器控件

2012-01-02 
求解,帮我把ASP代码翻译成ASP.NET关键在前面%%里面,后面只是调用播放器控件scriptlanguagejavascript

求解,帮我把ASP代码翻译成ASP.NET关键在前面<%%>里面,后面只是调用播放器控件
<script   language=javascript>
function   go_resize(gs)
{
    var   Left_size   =   (screen.width)   ?   (screen.width-555)/2   :   0;
    if   (gs== "- ")
    {
        window.resizeTo(555,580);
        window.moveTo(Left_size,0);
        document.all.g2.disabled=true;
        document.all.g1.disabled=false;
    }
    else
    {
        Left_size   =   (screen.width)   ?   (screen.width-740)/2   :   0;
        window.resizeTo(740,700);
        window.moveTo(Left_size,0);
        document.all.g1.disabled=true;
        document.all.g2.disabled=false;
    }
}
</script>


<%
Set   objgetjzvg=Server.CreateObject( "sqlmoviereal.getjzvg ")
connectvg=objgetjzvg.connectvg(serverdz,   sqlreal,   urlid,   real,   allplayer,   filename,   netbarname)
Set   objgetjzvg=nothing
connectvglist=split(connectvg, ", ")
%>
<script   language= "JScript ">
document.onkeydown   =   function()
{if(event.keyCode   !=   27)
{event.keyCode   =   0;
  event.returnValue   =   false;
  }
  }
function   PlayerError()
{if(window.opener   ==   undefined)history.back(-1);
else   self.close();
}
</script>
<table   align= "center "   cellspacing= "0 "   cellpadding= "0 "   width= "100% "   border= "0 "> <tr> <td   align= "center "   valign= "middle ">
<object   id= "JzPlayer "   width= "1024 "   height= "768 "   classid= "CLSID:AA899B43-24BD-4B6B-BBD0-45557D8D11E0 "   VIEWASTEXT>
<param   name= "_Version "   value= "65536 ">
<param   name= "_ExtentX "   value= "10583 ">
<param   name= "_ExtentY "   value= "10583 ">
<param   name= "_StockProps "   value= "0 "> </object>
<input   name= "g1 "   type= "hidden "   value= "g1 ">
<input   name= "g2 "   type= "hidden "   value= "g2 ">
</td> </tr> </table>
<script   language= "JScript ">
x   =   CheckPlayer();
function   PlayerInit(szServerHost)
{
JzPlayer.ServerMode   =   "2 ";
  JzPlayer.UserName=   " <%=netbarname%> ";
JzPlayer.UserID=   " <%=connectvglist(0)%> ";
JzPlayer.PlayMode=   "1 ";
JzPlayer.PlayModeValue   =   " <%=connectvglist(1)%> ";  
JzPlayer.ChannelID=   " <%=connectvglist(1)%> ";
JzPlayer.AuthenHost   =   " <%=connectvglist(2)%> :80 ";
JzPlayer.ServerHost   =   "1.1.1.1 ";  
JzPlayer.Session=   " ";  
JzPlayer.ProtocolType   =   "1 ";
JzPlayer.EmbedMode=   "1 ";


JzPlayer.ProgName=   " <%=filename%> ";
JzPlayer.ContorlWidth=   322;
JzPlayer.ContorlHeight   =   320;
JzPlayer.Start();
  }
 
function   RestorePlayerWindow(iWidth,   iHeight)
{
window.resizeTo(iWidth,   iHeight);
availWidth=   screen.Width;
availHeight=   screen.availHeight;
iTmpPix=   availWidth   -   iWidth;
iWinLeft=   iTmpPix   /   2;
iTmpPix=   availHeight   -   iHeight;
iWinHeight=   iTmpPix   /   2;
window.moveTo(iWinLeft,   iWinHeight);
}

function   CheckPlayer()
{
try
{
var   oTest   =   new   ActiveXObject( "VGPlayer.WebVGPlayer.1 ");
}
catch(e)
{
if(window.opener   ==   undefined)
{
window.alert( "首次点播将安装本站专用播放器以获得最佳的播放效果... ");
window.open( "soft/RealMedia.exe ");
history.back(-1);
}
else
{
window.opener.alert( "首次点播将安装本站专用播放器以获得最佳的播放效果... ");
window.opener.open( "soft/RealMedia.exe ");
self.close();
}
return   false;
}
delete   oTest;

PlayerInit( "1.1.1.1 ");
return   true;
}
</script>

这是我ASP播放页面的代码..关键部分Set想改成.NET(C#)老是出错,求高手解

[解决办法]
JzPlayer.UserName= " <%=netbarname%> ";
JzPlayer.UserID= "你自己的设置 ";
JzPlayer.PlayMode= "1 ";
JzPlayer.PlayModeValue = "你自己的设置 ";
............
[解决办法]
本家,你又在了,

热点排行