调整Flash对象的大小

Fel*_* K. 0 html embed flash resize

我试图将flash对象的高度调整为分隔符的大小.这实际上不起作用,所以这里有什么问题?显示flash对象,但它的高度仅为100px.我想稍后通过从flash调用js-method并更改div对象的大小来调整大小.

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Index.aspx.cs" Inherits="Website.Pages.Index" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
        <div align="center">
            <div id="contentDivider" style="width:780;height:600;">
                <object width="780" height="100%">
                  <embed src="../content/Home.swf" type="application/x-shockwave-flash" width="780" height="100%" allowScriptAccess="sameDomain" pluginspage="http://get.adobe.com/de/flashplayer/"></embed>
                </object>
            </div>
        </div>
    </form>
    <script language="javascript" type="text/javascript">
        function setFlashHeight(height) {
            contentDivider.style.height = height;
        }
    </script>
</body>
</html>
Run Code Online (Sandbox Code Playgroud)

干杯菲利克斯

Mar*_*ein 5

我不得不在前一段时间通过html拖动创建一个可调整大小的flash对象,这是我的解决方案:

  • 我用%尺寸创建了flash对象,例如height:100%;
  • 我调整了flash html容器的大小,闪光灯应该跟随div的高度.

请让我知道这对你有没有用.

<div style="height:500px;">
<object style='height:100%;'><embed/></object>
</div>
Run Code Online (Sandbox Code Playgroud)

调整大小div,应该没问题