2012-02-22 29 views
2
<a href="#dialog" name="modal">Simple Modal Window</a> 

<div id="boxes"> 
this should be under modal 

    <!-- #customize your modal window here --> 

    <div id="dialog" class="window"> 
     <b>Testing of Modal Window</b> | 

     <!-- close button is defined as close class --> 
     <a href="#" class="close">Close it</a> 

    </div> 
    <br /> 
    this also 
    <!-- Do not remove div#mask, because you'll need it to fill the whole screen --> 
    <div id="mask"></div> 
</div> 

LIVE:http://jsfiddle.net/ruwmh/模态窗口 - 如何在所有屏幕上?

如何使这一模式的屏幕是所有的屏幕上?现在,这个心不是Ø

回答

3

您应该更改CSS像这样

#mask { 
    position:absolute; 
    z-index:9000; 
/*add left and top to position to upper left */ 
left:0; 
    top:0; 
    background-color:#000; 
    display:none; 
} 

小提琴这里http://jsfiddle.net/ruwmh/1/