国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 編程 > HTML > 正文

網頁中flash wmode屬性你會用嗎?

2019-10-26 17:24:16
字體:
來源:轉載
供稿:網友

在做web開發中可能會遇到flash遮擋頁面中元素的情況,無論怎么設置flash容器和層的深度(z-index)也無濟于事,現有的解決方案是在插入flash的embed或object標簽中加入”wmode”屬性并設置為wmode=“transparent”或”opaque”,但wmode屬性到底是什么意義,為什么可以解
在flash標簽中
<param name=”wmode" value="xxxx">
"Window" 在 Web 頁上用影片自己的矩形窗口來播放應用程序,并且始終位于最頂層。
"Opaque" 顯示頁面上位于它后面的內容。
"Transparent"使 HTML 頁的背景可以透過應用程序的所有透明部分顯示出來,并且可能會降低動畫性能。
注:"Opaque"和"Transparent"都可與 HTML 層交互,從而允許 SWF 文件上方的層遮蔽應用程序。這兩種選項之間的差異在于"Transparent"允許透明,因此,如果 SWF 文件的某一部分是透明的,則 SWF 文件下方的 HTML 層可以透過該部分顯示出來,而"opaque"則不會顯示。
也就是如果發生FLASH遮蓋DIV層的情況,就必須要改wmode屬性為“Transparent”
在做web開發中可能會遇到flash遮擋頁面中元素的情況,無論怎么設置flash容器和層的深度(z-index)也無濟于事,現有的解決方案是在插入flash的embed或object標簽中加入”wmode”屬性并設置為wmode=“transparent”或”opaque”,但wmode屬性到底是什么意義,為什么可以解決這個問題呢?
window mode(wmode)
wmode即窗口模式總共有三種,看看當年Macromedia官方的說法: Window: Use the Window value to play a Flash Player movie in its own rectangular window on a web page. This is the default value for wmode and it works the way the classic Flash Player works. This normally provides the fastest animation performance. Opaque: By using the Opaque value you can use JavaScript to move or resize movies that don’t need a transparent background. Opaque mode makes the movie hide everything behind it on the page. Additionally, opaque mode moves elements behind Flash movies (for example, with dynamic HTML) to prevent them from showing through. Transparent: Transparent mode allows the background of the HTML page, or the DHTML layer underneath the Flash movie or layer, to show through all the transparent portions of the movie. This allows you to overlap the movie with other elements of the HTML page. Animation performance might be slower when you use this value.
window 模式
默認情況下的顯示模式,在這種模式下flash player有自己的窗口句柄,這就意味著flash影片是存在于Windows中的一個顯示實例,并且是在瀏覽器核心顯示窗口之上的,所以flash只是貌似顯示在瀏覽器中,但這也是flash最快最有效率的渲染模式。由于他是獨立于瀏覽器的HTML渲染表面,這就導致默認顯示方式下flash總是會遮住位置與他重合的所有DHTML層。
發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表

圖片精選

主站蜘蛛池模板: 开原市| 建德市| 永春县| 苗栗县| 商都县| 额济纳旗| 桐乡市| 吴桥县| 宝丰县| 遵化市| 焦作市| 乌拉特中旗| 嘉善县| 汉川市| 安丘市| 定陶县| 普兰店市| 巴彦淖尔市| 武城县| 鄂托克旗| 舒兰市| 金堂县| 齐河县| 平舆县| 丰原市| 高淳县| 那坡县| 南木林县| 徐闻县| 深水埗区| 休宁县| 婺源县| 龙门县| 禹城市| 正蓝旗| 昌宁县| 齐齐哈尔市| 丽江市| 皮山县| 奈曼旗| 灯塔市|