Make flash appear full screen in a Web page

Source: Internet
Author: User
Page | show

We are often in the production of web pages to make our flash implementation in the Web page all display, that is, the Web page in addition to flash no longer show other content, first of all to do a demo page , we can see the effect.

In fact, this effect is very simple, mainly using the release of Flash features and CSS technology implementation.

Specific production process:

1. Start our Flash MX 2004 and open a source file that already exists.

2. Select the File menu, select Publish settings from, select the HTML tab in the dialog box that appears, and then set the following figure:

3. Then click on the "Publish" button to publish the video, notice where it's posted? When we open the path we publish to, we will find that two files exist: one is the extension. SWF, and another for. HTML file, when we right-click. HTML file, choose Open mode for Notepad to open will see the code, the code is as follows:

<! DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 transitional//en" "Http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd ">
The above is a document type description statement that is not executed in an HTML file.
<meta http-equiv= "Content-type" content= "text/html; charset=gb2312 "/>
<title>myfile</title>
<body bgcolor= "#ffffff" >
The url--> used in <!--films
<!--text used in a movie-->
<object classid= "clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase= "http://fpdownload.macromedia.com/pub/ shockwave/cabs/flash/
swflash.cab#version=7,0,0,0 "width=" 100% "height=" 100% "id=" myfile "align=" Middle ">
<param name= "allowscriptaccess" value= "Samedomain"/>
<param name= "movie" value= "http://www.webjx.com/htmldata/2005-04-15/myfile.swf"/>
<param name= "Quality" value= "High"/>
<param name= "scale" value= "Noscale"/>
<param name= "bgcolor" value= "#ffffff"/>
<embed src= "http://www.webjx.com/htmldata/2005-04-15/myfile.swf" quality= "High" scale= "Noscale" "bgcolor=" FFFFFF "width=" 100% "height=" 100% "name=" myfile "align=" Middle "allowscriptaccess=" Samedomain "type=" application/ X-shockwave-flash "Pluginspage=http://www.macromedia.com/go/getflashplayer/>
</object>
</body>

4. This is if we double-click to open. HTML file in IE Browse, you can find that is not the Flash file is full of the entire page, because most browsers have set a default border, then if we want to let flash full of the entire page, we must use CSS to achieve! Add the following CSS code to the <HEAD> and < P head> area of the HTML file above. Then double-click to open in IE Browse will see already filled the entire page!

The specific code for CSS is as follows:

<style type= "Text/css" >
<!--
Body {
height:100%;
width:100%;
margin:0;
}
-->
</style>

5. Finally provides the demonstration effect: Click here to see the effect click here to download source files (including. fla,.swf,html files) 



Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.