我承認新的JavaScript,因此恩典讚賞...的JavaScript的getElementById iframe的整合
答:我想申請的getelementbyId
功能(我認爲)WITHOUT jQuery和
B.我想將它應用到整個桌子上,但每個元素都有不同的懸停圖像或狀態......任何幫助非常感謝!
<code>
<article class="main_display">
<p style="text-align: center;"><iframe id="bigVideo" width="850" height="500" src="http://player.vimeo.com/video/45587075?rel=0&autoplay=0&modestbranding=1&wmode=Opaque" frameborder="0" allowfullscreen></iframe>
<table width="142" cellspacing="1" cellpadding="2" id="mouseOvers">
<tr>
<td><a href="#" onclick="$('#bigVideo').attr('src', 'http://player.vimeo.com/video/46124645?rel=0&autoplay=1&modestbranding=1&wmode=Opaque')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Image7','','http://s3.amazonaws.com/worship/graphics/worshipmadness/play_rollover.jpg',1)"><img src="http://s3.amazonaws.com/worship/graphics/worshipmadness/week1_vid.jpg" name="Image7" width="140" height="142" border="0" id="Image7" /></a></td>
<td><a href="#" onclick="$('#bigVideo').attr('src', 'http://player.vimeo.com/video/46117474?rel=0&autoplay=1&modestbranding=1&wmode=Opaque')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Image2','','http://s3.amazonaws.com/worship/graphics/worshipmadness/play_rollover.jpg',1)"><img src="http://s3.amazonaws.com/worship/graphics/worshipmadness/week2_vid.jpg" name="Image2" width="142" height="142" border="0" id="Image2" /></a></td>
<td><a href="#" onclick="$('#bigVideo').attr('src', 'http://player.vimeo.com/video/46117474?rel=0&autoplay=1&modestbranding=1&wmode=Opaque')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Image3','','http://s3.amazonaws.com/worship/graphics/worshipmadness/play_rollover.jpg',1)"><img src="http://s3.amazonaws.com/worship/graphics/worshipmadness/week3_vid.jpg" name="Image3" width="142" height="142" border="0" id="Image3" /></a></td>
<td><a href="#" onclick="$('#bigVideo').attr('src', 'http://player.vimeo.com/video/46119637?rel=0&autoplay=1&modestbranding=1&wmode=Opaque')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Image4','','http://s3.amazonaws.com/worship/graphics/worshipmadness/play_rollover.jpg',1)"><img src="http://s3.amazonaws.com/worship/graphics/worshipmadness/week4_vid.jpg" name="Image4" width="142" height="142" border="0" id="Image4" /></a></td>
<td><a href="#" onclick="$('#bigVideo').attr('src', 'http://player.vimeo.com/video/46121214?rel=0&autoplay=1&modestbranding=1&wmode=Opaque')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Image5','','http://s3.amazonaws.com/worship/graphics/worshipmadness/play_rollover.jpg',1)"><img src="http://s3.amazonaws.com/worship/graphics/worshipmadness/week5_vid.jpg" name="Image5" width="142" height="142" border="0" id="Image5" /></a></td>
<td><a href="#" onclick="$('#bigVideo').attr('src', 'http://player.vimeo.com/video/46123371?rel=0&autoplay=1&modestbranding=1&wmode=Opaque')" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Image6','','http://s3.amazonaws.com/worship/graphics/worshipmadness/play_rollover.jpg',1)"><img src="http://s3.amazonaws.com/worship/graphics/worshipmadness/week6_vid.jpg" name="Image6" width="142" height="142" border="0" id="Image6" /></a></td>
</tr>
</table>
</p>
</article>
</code>
您必須更具體地瞭解您要完成的任務,並向我們展示您當前使用的代碼。兩者在獲得幫助方面都會有很長的路要走。 – jackwanders 2012-08-02 15:13:47
謝謝,對不起,代碼沒有正確發佈......但現在我們很好。 – lsaintj 2012-08-02 15:15:34
你期望getElementById做什麼? – scrappedcola 2012-08-02 15:20:59