A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: swf object and div layer

  1. #1
    Flashmatics silentweed's Avatar
    Join Date
    Mar 2005
    Location
    London, UK
    Posts
    4,875

    swf object and div layer

    I have a flash movie main.swf which plays an flv file. This will be fullscreen..however initially when you come to the html page containing it...it should only show a portion of the flash file..I am using div layers to accomplish this...however the flash movie dimensions seem to be set to 100% height and width of the div tag instead of the browser width and height..how can I make the swf 100% ehight/width of the browser and not the div tag it is within? The code is as follows:

    PHP Code:
    <script type="text/javascript" src="swfobject.js"></script><style type="text/css">
    <!--
    body {
        
    margin-left0px;
        
    margin-top0px;
        
    margin-right0px;
        
    margin-bottom0px;
    }
    #flashcontent {
        
    position:absolute;
        
    overflow:hidden;
        
    left:190px;
        
    top:328px;
        
    width:267px;
        
    height:164px;
    }
    -->
    </
    style>


    <
    div id="flashcontent">
      
    This text is replaced by the Flash movie.
    </
    div>

    <
    script type="text/javascript">
       var 
    so = new SWFObject("main.swf""mymovie""100%""100%""8""#336699");
       
    so.write("flashcontent");
    </
    script
    Any help is much appreciated...cheers
    Last edited by silentweed; 09-10-2008 at 07:48 AM.
    Flashmatics | Flashmatics Library (free downloads)
    -----------------------------------------------------
    Latest Projects:
    The Dead Room | Are You Smarter | Prison Break (Frame A Friend) | Beck's Fusions | The 24 Experience

    -----------------------------------------------------
    Flash Certified Developer

  2. #2
    Senior Member whispers's Avatar
    Join Date
    Mar 2001
    Location
    CFA2h (respect the HEX)
    Posts
    12,755
    Im not sure Im following..

    but in the CSS:

    #flashcontent {
    position:absolute;
    overflow:hidden;
    left:190px;
    top:328px;
    width:267px;
    height:164px;
    }

    or.. maybe resize the div container dynamically?

    cant you make the flashcontent 100%

  3. #3
    Flashmatics silentweed's Avatar
    Join Date
    Mar 2005
    Location
    London, UK
    Posts
    4,875
    cheers whispers..dont worry about it..our javascript guy ended up sorting it out ... css not my cup of tea lol
    Flashmatics | Flashmatics Library (free downloads)
    -----------------------------------------------------
    Latest Projects:
    The Dead Room | Are You Smarter | Prison Break (Frame A Friend) | Beck's Fusions | The 24 Experience

    -----------------------------------------------------
    Flash Certified Developer

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center