Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Offset, But Central Flash Object 1

Status
Not open for further replies.

TheVillageIdiot27

Programmer
Nov 10, 2005
58
GB
I can't believe I can't get this to work accross more than one browser but here goes.

I have a flash object at the top of a page sitting in a div cunningly called "header" underneath this there is effectivly two columns one 300px wide which contains the navigation and then the rest of the page width is taken up by the content section.

The problem is I need to get the flash header to be be central over the content section, which I assumed I could achieve in the following way.

HTML
Code:
			<div id="header">
				<object width="100%" align="middle" height="111" name="flashheader" title="Flash Navigation" type="application/x-shockwave-flash" data="header.swf">
					<param name="movie" value="header.swf" />
				</object>
			</div>

CSS
Code:
#header
{
	width: 100%;
	height: 120px;
}
#header object
{
	.margin-left: 300px;
	
}

Which seems to work in IE but not matter what I try I can't seem to get it to work in Firefox.

If anyone could shed any light I would be most grateful.

Thanks In Advance.
 
How about simply doing the:
Code:
#header
{
    margin-left: 300px;
    height: 120px;
}
Incidentally, adding a dot in front of margin-left will cause that property to be ignored, as it is invalid.
 
Sorry the dot was a typo...

Absolutly nothing is wrong with that though, can't believe I didn't try that - I tried that with but with a 100% width to the div which made an almighty mess.

Thanks for the help.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top