<object id="jnkcObj" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000">
<param name="Movie" value="http://ecards.sina.com.cn/2000/2002-12-24/112738510.swf">
</object>
<embed id="jnkcFlash" width="128" height="128" src="http://ecards.sina.com.cn/2000/2002-12-24/112738510.swf">
<script language="JavaScript">
<!--
var jnkcUrl = 'http://ecards.sina.com.cn/2000/2002-2-19/15064859768.swf';
jnkcFlash.src = jnkcUrl;
jnkcObj.movie = jnkcUrl;
//-->
</script>
<param name="Movie" value="http://ecards.sina.com.cn/2000/2002-12-24/112738510.swf">
</object>
<embed id="jnkcFlash" width="128" height="128" src="http://ecards.sina.com.cn/2000/2002-12-24/112738510.swf">
<script language="JavaScript">
<!--
var jnkcUrl = 'http://ecards.sina.com.cn/2000/2002-2-19/15064859768.swf';
jnkcFlash.src = jnkcUrl;
jnkcObj.movie = jnkcUrl;
//-->
</script>
解决方案 »
- 做一次伸手党。。
- JS语法问题
- MVC easyui datagrid 值问题
- 再谈JAVASCRIPT最大化窗口的问题
- 求,URL中移动portal,JS怎样使图标的平铺改为拉伸?
- 谁能给我点asp的showmoal的例子呀!
- <a href="JavaScript:top.right.goRef('r_chap06.htm','rArendhorst')">Arendhorst</a>
- 如何把表单里一个(非Submit)按钮设为默认按钮,使用户可以直接按回车,不必每次都用鼠标点?
- MM在线等待!百年不遇的window.location.href问题?
- 咨询一个冒泡问题的解决办法
- 如何请弹出窗口关闭后的返回参数?
- EJB和JAVABAEN有什么区别呢??
<param name="Movie" value="http://ecards.sina.com.cn/2000/2002-12-24/112738510.swf">
</object>
<embed id="jnkcFlash" width="128" height="128" src="http://ecards.sina.com.cn/2000/2002-2-19/15064859768.swf">
<script language="JavaScript">
<!--
alert(jnkcObj.movie+'\n'+jnkcFlash.src);
//-->
</script>
很好的办法。谢谢。但是我还有更高的要求。能不能再帮我下。
假如<object>标签没有div属性怎么办?我在发顶贴的时候是用document.embeds[i].src和document.images[i].src取到src的。就是因为我需要处理的是一段html代码,把其中的非文字元素的src替换成文件名(不带http://...)。
<OBJECT classid=CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95 codeBase=http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,05,0809 height=256 id=NSOPlay type=application/x-oleobject width=245 standby="Connecting with Live Event. Please wait patiently...">
<PARAM NAME="AudioStream" VALUE="-1">
<PARAM NAME="AutoSize" VALUE="-1">
<PARAM NAME="AutoStart" VALUE="-1">
<PARAM NAME="AnimationAtStart" VALUE="-1">
<PARAM NAME="AllowScan" VALUE="-1">
<PARAM NAME="AllowChangeDisplaySize" VALUE="-1">
<PARAM NAME="AutoRewind" VALUE="-1">
<PARAM NAME="Balance" VALUE="-1">
<PARAM NAME="BaseURL" VALUE="">
<PARAM NAME="BufferingTime" VALUE="5">
<PARAM NAME="CaptioningID" VALUE="-1">
<PARAM NAME="ClickToPlay" VALUE="-1">
<PARAM NAME="CursorType" VALUE="-1">
<PARAM NAME="CurrentPosition" VALUE="-1">
<PARAM NAME="CurrentMarker" VALUE="-1">
<PARAM NAME="DefaultFrame" VALUE="content">
<PARAM NAME="DisplayBackColor" VALUE="0">
<PARAM NAME="DisplayForeColor" VALUE="16777215">
<PARAM NAME="DisplayMode" VALUE="0">
<PARAM NAME="DisplaySize" VALUE="4">
<PARAM NAME="Enabled" VALUE="-1">
<PARAM NAME="EnableContextMenu" VALUE="-1">
<PARAM NAME="EnablePositionControls" VALUE="-1">
<PARAM NAME="EnableFullScreenControls" VALUE="-1">
<PARAM NAME="EnableTracker" VALUE="-1">
<PARAM NAME="Filename" VALUE="http://go6.163.com/colorweb/play.asx">
<PARAM NAME="InvokeURLs" VALUE="-1">
<PARAM NAME="Language" VALUE="-1">
<PARAM NAME="Mute" VALUE="0">
<PARAM NAME="PlayCount" VALUE="-1">
<PARAM NAME="PreviewMode" VALUE="0">
<PARAM NAME="Rate" VALUE="1">
<PARAM NAME="SAMILang" VALUE="">
<PARAM NAME="SAMIStyle" VALUE="">
<PARAM NAME="SAMIFileName" VALUE="">
<PARAM NAME="SelectionStart" VALUE="-1">
<PARAM NAME="SelectionEnd" VALUE="-1">
<PARAM NAME="SendOpenStateChangeEvents" VALUE="-1">
<PARAM NAME="SendWarningEvents" VALUE="-1">
<PARAM NAME="SendErrorEvents" VALUE="-1">
<PARAM NAME="SendKeyboardEvents" VALUE="0">
<PARAM NAME="SendMouseClickEvents" VALUE="-1">
<PARAM NAME="SendMouseMoveEvents" VALUE="-1">
<PARAM NAME="SendPlayStateChangeEvents" VALUE="-1">
<PARAM NAME="ShowCaptioning" VALUE="0">
<PARAM NAME="ShowControls" VALUE="-1">
<PARAM NAME="ShowAudioControls" VALUE="-1">
<PARAM NAME="ShowDisplay" VALUE="-1">
<PARAM NAME="ShowGotoBar" VALUE="0">
<PARAM NAME="ShowPositionControls" VALUE="-1">
<PARAM NAME="ShowStatusBar" VALUE="-1">
<PARAM NAME="ShowTracker" VALUE="-1">
<PARAM NAME="TransparentAtStart" VALUE="-1">
<PARAM NAME="VideoBorderWidth" VALUE="0">
<PARAM NAME="VideoBorderColor" VALUE="0">
<PARAM NAME="VideoBorder3D" VALUE="0">
<PARAM NAME="Volume" VALUE="-450">
<PARAM NAME="WindowlessVideo" VALUE="0">
<EMBED type="video/x-ms-asf-plugin" pluginspage="http://www.microsoft.com/goto/mscom/windows/mediaplayer/default.asp" filename="http://colorweb.go.163.com/play.asx"
name="NSOPlay"
width="286"
height="172"
DefaultFrame="content"
AnimationAtStart="-1"
AutoRewind="-1"
AutoStart="-1"
Autosize="-1"
ControlType="-1"
DisplaySize="6"
ShowAudioControls="-1"
ShowControls="-1"
ShowDisplay="-1"
ShowGotoBar="-1"
ShowPositionControls="-1"
ShowStatusBar="-1"
ShowTracker="-1"
TransparentAtStart="-1">
</EMBED>
</OBJECT>
<br/>
<input onclick="document.all.NSOPlay.pause()" type=button value="停止">
<input onclick="document.all.NSOPlay.play()" type=button value="播放">
<input onclick="document.all.NSOPlay.ShowStatusBar='0'" type=button value="没有状态栏">
<input onclick="document.all.NSOPlay.Volume='-1000'" type=button value="减小声音">
<input onclick="document.all.NSOPlay.Volume='0'" type=button value="增大声音">
<input onclick="document.all.NSOPlay.Stop();document.all.NSOPlay.CurrentPosition=0;document.all.NSOPlay.play()" type=button value="回放">
<input onclick="document.all.NSOPlay.Previous()" type=button value="上一首">
<input onclick="document.all.NSOPlay.Next()" type=button value="下一首">
<input onclick="document.all.NSOPlay.FastForward()" type=button value="快进">你是用document.all.NSOPlay引用的播放器
我想实现的是如果网页中有一个名字不可预知的播放器(比如在浏览器里ctrl+A,然后在frontpage里ctrl+c)
我怎么得出播放器播放的源地址,
这儿的就是http://go6.163.com/colorweb/play.asx。我想把http://go6.163.com/colorweb/play.asx换成play.asx
得到这个对象可以用document.getElementsByTagName("object")[0]或document.all.tags("OBJECT")[0].然后用childNode来得到param,不知有没有直接的方法?
能不能直接给出得到param的代码,我没有写出来。
<br><br><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=4,0,2,0" width="200" height="200">
<param name="_cx" value="5292">
<param name="_cy" value="5292">
<param name="FlashVars" value="-1">
<param name="Movie" value="http://ecards.sina.com.cn/2000/2002-12-24/112738510.swf">
<param name="Src" value="http://ecards.sina.com.cn/2000/2002-12-24/112738510.swf">
<param name="WMode" value="Window">
<param name="Play" value="-1">
<param name="Loop" value="-1">
<param name="Quality" value="High">
<param name="SAlign" value>
<param name="Menu" value="-1">
<param name="Base" value>
<param name="AllowScriptAccess" value="always">
<param name="Scale" value="ShowAll">
<param name="DeviceFont" value="0">
<param name="EmbedMovie" value="0">
<param name="BGColor" value>
<param name="SWRemote" value><embed src="http://ecards.sina.com.cn/2000/2002-12-24/112738510.swf" quality="high" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="32" height="32">
</object>
<script>
alert( document.all.tags("OBJECT").length)
alert( document.all.tags("OBJECT")[0].Movie)
</script>