MediaMonkey Posted July 24, 2008 Share Posted July 24, 2008 Hello... I've got an issue that I could really do with help on: I would like a flash (.swf) background; to be W:100% / H:100%... However, would like to put HTML content on top of this (using Dreamweaver). Therefore, I would like some help with scripting an include sort of file... So that the background is generated and brought in; with HTML content loaded on top. So far, I've put together: Pager.php (The page to have HTML content on it): <?php session_start(); ?><?php include("background.php"); ?> <html> <head> <title>Untitled Document</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> </head> <body background="<?=$_SESSION['background']?>"> </body> </html> And then the script for background: <?php session_start(); if(!$_SESSION['background']) $_SESSION['background'] = 'BACKGROUND.swf'; ?> A seperate script I've been using to get the background re-sizing to monitors at 100% is: <script type="text/javascript" src="swfobject_source.js"></script> </head> <body> <div align="center"> <div class="style1" id="flashcontent"> <a href="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash&promoid=BIOW" class="style2">You need to upgrade your Flash Player</a> </div> <script type="text/javascript"> // <![CDATA[ var so = new SWFObject("BACKGROUND.swf", "Preview", "100%", "100%", "8", "#14191C", true); so.addParam("scale", "noscale"); so.addParam("salign", "lt"); so.write("flashcontent"); // ]]> </script> </div> Now I need some help putting it all together, so that the flash background is loaded in through an include file, to 100% x 100%; and I can put content ontop (and the background won't scroll). Any ideas?? ??? Thank you for your help! MediaMonkey Quote Link to comment Share on other sites More sharing options...
MediaMonkey Posted July 24, 2008 Author Share Posted July 24, 2008 Does anyone know if this is possible? I've seen it works for random .JPG files? Thanks, MM Quote Link to comment Share on other sites More sharing options...
Jabop Posted July 24, 2008 Share Posted July 24, 2008 Apply z-index on your divs? Quote Link to comment Share on other sites More sharing options...
MediaMonkey Posted July 24, 2008 Author Share Posted July 24, 2008 Hi, Thanks for your reply... I tried Z-indexing - but it doesn't work in that dreamweaver always puts flash content on top... Also I read that this is unreliable for browsers when loading, as to which order they appear? Thanks, MM Quote Link to comment Share on other sites More sharing options...
Jabop Posted July 24, 2008 Share Posted July 24, 2008 You could use javascript onLoad for that. However, now that I think of it, I am not sure if you could even place a div that is positioned over the flash piece. I mean you could, but I think that the flash object will always be on top due to browser rendering. (I could be wrong) Quote Link to comment Share on other sites More sharing options...
MediaMonkey Posted July 24, 2008 Author Share Posted July 24, 2008 That's what I thought too... Thats why I wondered about the prospect of loading the background in from an include function; that way I could setup the background with 100% params in one file and then include it on the page which is going to have the content? Thanks, MM Quote Link to comment Share on other sites More sharing options...
DarkWater Posted July 24, 2008 Share Posted July 24, 2008 No, you can't include a .swf into a PHP file. Simply said. I mean, there are libraries to WORK with Flash in PHP, and you can check those out, but you can't directly include a swf into PHP. Quote Link to comment Share on other sites More sharing options...
MediaMonkey Posted July 24, 2008 Author Share Posted July 24, 2008 Thanks darkwater; how about embedding the flash file into another .PHP -> then embed that? MM Quote Link to comment Share on other sites More sharing options...
Jabop Posted July 24, 2008 Share Posted July 24, 2008 DarkWater is right. MediaMonkey, could you be more descriptive with what you're trying to do? Then we could possibly find a solution. Quote Link to comment Share on other sites More sharing options...
MediaMonkey Posted July 24, 2008 Author Share Posted July 24, 2008 I'll try Jabop: I have a flash-fx background, which re-sizes according to the dimensions of the users browser. I would just like to use that as the background as non-scrolling, with HTML scrollable content on top. Thank you for your help MM Quote Link to comment Share on other sites More sharing options...
DarkWater Posted July 24, 2008 Share Posted July 24, 2008 I fairly sure that you can't do that at all. Unless you actually put the content into the Flash object when you make it. Quote Link to comment Share on other sites More sharing options...
MediaMonkey Posted July 24, 2008 Author Share Posted July 24, 2008 Are there no work-arounds at all? Thanks, MM Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.