showModalDialog(“你的URL”,调入参数,“窗口大小风格”)

解决方案 »

  1.   

    <script language=javascript>
    function init(){
          showModalDialog(“你的URL”,调入参数,“窗口大小风格”)
    }
    </script><html><body onload="init()">
    ..........
    </body>
    </html>
      

  2.   

    仅做参考,代码你可以自行修改。<script language="JavaScript">
    <!--
    function openPictureWindow_Fever(imageName,imageWidth,imageHeight,alt) {
        var posLeft,posTop;
    posLeft=(screen.width-imageWidth)/2;
    posTop=(screen.height-imageHeight)/2;
    newWindow = window.open("","newWindow","width="+imageWidth+",height="+imageHeight+",left="+posLeft+",top="+posTop);
    newWindow.document.open();
    newWindow.document.write('<html><title>'+alt+'</title><body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginheight="0" marginwidth="0">'); 
    newWindow.document.write('<img src='+imageName+' width='+imageWidth+' height='+imageHeight+' alt='+alt+'>'); 
    newWindow.document.write('</body></html>');
    newWindow.document.close();
    newWindow.focus();
    }
    //-->
    </script>