Forum Moderators: coopster
I am trying to align my video to the center but I am missing a line of code it is currently aligned to the left ?
anyone knows how to align it to the right.
<div id="container"><a href="http://www.macromedia.com/go/getflashplayer">Get the Flash Player</a> to see this player.</div>
<script type="text/javascript" src="swfobject.js"></script>
<script type="text/javascript">
var s1 = new SWFObject("player.swf","ply","328","200","9","#FFFFFF");
s1.addParam("allowfullscreen","true");
s1.addParam("allowscriptaccess","always");
s1.addParam("flashvars","file=myvideo.flv&image=preview.jpg");
s1.write("container");
</script>
Thank you for your help,
You may want to look at the CSS property text-align, as generally browsers will align all content to this value (just be careful as the value is inherited).
You could also use padding to force the object into one side of the box.