Link to home
Start Free TrialLog in
Avatar of weikelbob
weikelbobFlag for United States of America

asked on

alignment of swf object

Hello,

In dreamweaver, I have a full page that is for flash. My swf file aligns center fine horizontally, but I cannot get it to align center vertically.

How do I do this?

Bob
Avatar of CoolATIGuy
CoolATIGuy

Try this:

<table width="100%" height="100%">
      <tr>
            <td align="center" valign="middle">
                  Blah Blah Blah...Flash <object> tags and stuff
            </td>
      </tr>
</table>


CoolATIGuy
Avatar of weikelbob

ASKER

That still doesn't align the flash movie vertically. Horizontal centering is fine.

Bob
Really?  Seemed to work fine for me...can you post all the code you have on that page, and a link to the page, please?


CoolATIGuy
Sure,

Here's the link:

http://b-transfers.com/chunbiao/index.html


Here's the code:


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Untitled Document</title>
</head>

<body>

<table width="95%" height="95%">
     <tr>
          <td align="center" valign="middle">
                <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="600" height="400" align="middle">
            <param name="movie" value="flash/movie.swf">
            <param name="quality" value="high">
            <embed src="flash/movie.swf" width="600" height="400" align="middle" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash"></embed>
            </object>
         
          </td>
     </tr>
</table>




</body>
</html>
That's the same as I have, except for two things:

1. Take out both - align="middle" - in the <object> and <embed> tags.
2. Why is <table width="95%" height="95%"> 95% instead of 100%?


CoolATIGuy
...although it should work the way it was...


CoolATIGuy
Please take a look at this again. The movie moves to stay centered horizontally, but when I move the screen vertically, the flash movie does not move to center itself.

The link:

http://b-transfers.com/chunbiao/index.html

The code:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Untitled Document</title>
</head>

<body>

<table width="100%" height="100%">
     <tr>
          <td align="center" valign="middle">
                <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="600" height="400">
            <param name="movie" value="flash/movie.swf">
            <param name="quality" value="high">
            <embed src="flash/movie.swf" width="600" height="400" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash"></embed>
            </object>
         
          </td>
     </tr>
</table>




</body>
</html>

ASKER CERTIFIED SOLUTION
Avatar of CoolATIGuy
CoolATIGuy

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thank you
yep...have another great day. ;-)


CoolATIGuy