2012-07-19 77 views

回答

2

您可以position: absolute;z-index

http://jsfiddle.net/t35vL/

HTML做到這一點:

<iframe src="http://jsfiddle.net/"></iframe> 
<img src="http://flickholdr.com/600/400/dogs">​ 

CSS:

iframe{ 
    width: 600px; 
    height: 400px; 
    border : 2px solid black; 
    z-index: 2; 
} 

img{ 
    position: absolute; 
    left: 0; 
    top: 0; 
    z-index: 3; 
    opacity: 0.3; 
} 

...這樣的圖像分層的iframe,並防止點擊裏面。

1

你可以嘗試這樣的事情:

<iframe name="inlineframe" src="sample.html" frameborder="1" scrolling="auto" width="500" height="180" marginwidth="5" marginheight="5" ></iframe> 
    <div style="position:absolute; 
    left:0px; //edit as per iframe placement 
    top:0px; //edit as per iframe placement 
    z-index:-1; 
    padding:5px;"> 
    <img src="rac_ftp.PNG" width="500" height="180" /> 
    </div>