Iframe 为什么照片点击时不显示视频?

Iframe 为什么照片点击时不显示视频?,iframe,Iframe,我已经写了代码…我想通过点击照片在弹出窗口中使用iframe打开youtube视频。下面是我写的代码。 我已经写了代码…我想通过点击照片在弹出窗口中使用iframe打开youtube视频。下面是我写的代码 <iDOCTYPE html> <html> <head> <link rel="stylesheet" href="http://code.jquery.com/mobile/1.2.0/jquery.mobile-1.2.0

我已经写了代码…我想通过点击照片在弹出窗口中使用iframe打开youtube视频。下面是我写的代码。 我已经写了代码…我想通过点击照片在弹出窗口中使用iframe打开youtube视频。下面是我写的代码

<iDOCTYPE html>
<html>
    <head>
        <link rel="stylesheet" href="http://code.jquery.com/mobile/1.2.0/jquery.mobile-1.2.0.min.css" />
        <script src="http://code.jquery.com/jquery-1.8.2.min.js"></script>
        <script src="http://code.jquery.com/mobile/1.2.0/jquery.mobile-1.2.0.min.js"></script>

        <script></script>
    </head>

    <body>
        <div data-role="page" id="page1">
                <div data-role="div" id="div1"> 
                    <img src="image1.jpg" onclick="play()" width="200px" height="200px" id="Zu5XUbig5G0">   
                </div>
                    <div data-role="footer" data-position="fixed">
                        <a href="#popup2"><h4>Featured</h4></a>
                    </div>

        </div>

        <div data-role="popup" id="popup2" data-overlay-theme="a" data-theme="a" data-corners="false" data-tolerance="15,15">

                <script>
                    function play()
                    {
                    var vid=document.getElementById("div1").getElementsByTagName('img')[0].id;
                    //alert(vid);
                        {
                        alert(vid);
                       document.getElementById("popup2").innerHTML="<iframe src='http://www.youtube.com/embed/tyOy3kRzkcM' width='480' height='320' seamless='' id='plyerIframe1'></iframe>";
                        //alert(vid);
                        }   
                    }
                </script>                           



        </div>

    </body>

</html>