banner

[Rule] Rules  [Home] Main Forum  [Portal] Portal  
[Members] Member Listing  [Statistics] Statistics  [Search] Search  [Reading Room] Reading Room 
[Register] Register  
[Login] Loginhttp  | https  ]
 
Forum Index Thảo luận hệ điều hành Windows giúp mình chèn flash ko bị đè lên menu sổ !  XML
  [Programming]   giúp mình chèn flash ko bị đè lên menu sổ ! 11/05/2009 02:45:15 (+0700) | #1 | 180173
thoigiantroi
Member

[Minus]    0    [Plus]
Joined: 10/05/2009 15:06:21
Messages: 1
Offline
[Profile] [PM]
Thân chào các bạn !
Mình thiết kế web cho thành em, gần hoàn thành nhưng bị trục ytawcj chút xíu.

là thế này : sau khi chèn flash vào banner web thì nó lại đè lên menu sổ xuống.

em đx thử nhiều lần nhưng ko được


mình thiết kế web bằng fontpage

thiết kế flash bằng Sothink SWF Quicker

Chèn flash vào trang web bằng fontpage

khi mở lên rất tuyệt nhưng bấm chuột vào menu sổ nó lại nằm phía dưới ko thấy em nó.

banner flash thì lại nằm trên.

bạn mình nói dúng thêm code : <pama......>
nhưng ko thành. nó xuống dưới nhưng mất giao diện của flash chỉ thấy chữ, vậy mới đau chứ.

các bạn chỉ dùm mình cách tốt nhất nhé !
mình cảm ơn mọi người, nếu được mình mời kem ok.
[Up] [Print Copy]
  [Question]   Re: giúp mình chèn flash ko bị đè lên menu sổ ! 15/05/2009 07:06:41 (+0700) | #2 | 180624
lequi
Member

[Minus]    0    [Plus]
Joined: 29/04/2007 18:13:32
Messages: 77
Offline
[Profile] [PM]
bạn thử tham khảo bài viết này xem (sử dụng div position)
Nguồn: http://www.alohatechsupport.net/webdesignmaui/maui-web-design-articles/layer_flash_under_html.html

Is there a way to have a flash movie play below another layer like an html text heading or div tag?
Answer: Yes, this is actually fairly simple but is a several part process depending on how may different items you would like to position above the flash element.

1. First you must add the wmode parameter transparent to the flash object that is going to be embedded.

Like so... <param name="wmode" value="transparent" />

(notesmilie If you are using the swfobject.js method to embed your flash files (recommended) you can add the transparent parameter by simply using the example below to append to your current setup:

<script type="text/javascript">
var so = new SWFObject("movie.swf", "movie", "700", "300", "#ffffff");
so.addParam("wmode", "transparent");
so.write("flashcontent");
</script>



2. Now we need to wrap our flash movie in its own div tag and and apply some css so that we can set the position to be below the header text and description div.
(See example below for xhtml and css code.)


<div id="header">

<div id="flash">flash file goes here.</div>

</div>


And the accompanying css for the above is:
(note the z-index and absolute position for #flash div)


#flash {
width: 700px;
height: 300px;
position: absolute;
z-index: 0;
}

#header {
height: 300px;
margin-bottom: 30px;
text-align: left;
}




3. Ok, now lets go ahead and set up the html layers that will be displayed displayed above our flash content. In this case it will be an h1 header and a description that is in its own div that is above the flash media.

(Two items to be positioned over the flash movie)

The h1 css is: (note: feel free to style it however you want or use a different tag, the important thing is the z-index and absolute position.


h1 {
padding-top: 15px;
padding-bottom: 15px;
margin-left: 10px;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 24px;
color: #666666;
font-weight: bold;
position: absolute;
z-index: 1;
}


Now for the description css which is going to be in its own div tag containing text and will be positioned above the flash element as well: (note the z-index and the absolute position again)


.description {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 9px;
color: #FFFFFF;
margin-left: 15px;
margin-top: 35px;
padding: 5px;
font-weight: bold;
line-height: 14px;
position: absolute;
z-index: 1;
}


4. Thats it, the finished code in the body of a web page will look like this:
(note: Code is placed in the header div which has no z-index or absolute position necessary)


<div id="header">

<div id="flash">flash file goes here.</div>

<h1>Heading Text</h1>
<div class="description">Your description text</div>


</div>

And the final accompanying CSS is:


h1 {
padding-top: 15px;
padding-bottom: 15px;
margin-left: 10px;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 24px;
color: #666666;
font-weight: bold;
position: absolute;
z-index: 1;
}

.description {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 9px;
color: #FFFFFF;
margin-left: 15px;
margin-top: 35px;
padding: 5px;
font-weight: bold;
line-height: 14px;
position: absolute;
z-index: 1;
}

#flash {
width: 700px;
height: 300px;
position: absolute;
z-index: 0;
}

#header {
height: 300px;
margin-bottom: 30px;
text-align: left;
}


HTML Layers and Flash Position Summary:

How to layer a Flash movie below another html div tag or layer.
To position a flash movie under another html element basically you just need to give the flash move a parameter of wmode transparent and position it absolutely with a z-index of 0. Do this by putting the flash object in its own div and using css. (see examples above)


For the items that you would like positioned above the flash movie set their z-index to 1 and position them absolutely as well. After that it's just a matter of putting it all in the div or container that you would like applying the css and adjusting the margin and padding to your specific needs.
[Up] [Print Copy]
  [Question]   Re: giúp mình chèn flash ko bị đè lên menu sổ ! 15/05/2009 09:33:32 (+0700) | #3 | 180629
[Avatar]
canh_nguyen
Elite Member

[Minus]    0    [Plus]
Joined: 23/08/2004 18:55:09
Messages: 775
Location: Broken dream
Offline
[Profile] [PM] [WWW] [Yahoo!] [MSN] [ICQ]
Chỉ cần cái Code:
<param name="wmode" value="transparent" />
khi embed cái flash là được rồi.
[Up] [Print Copy]
[digg] [delicious] [google] [yahoo] [technorati] [reddit] [stumbleupon]
Go to: 
 Users currently in here 
1 Anonymous

Powered by JForum - Extended by HVAOnline
 hvaonline.net  |  hvaforum.net  |  hvazone.net  |  hvanews.net  |  vnhacker.org
1999 - 2013 © v2012|0504|218|