
Under normal circumstances, when we want to align images, WordPress will give us the options when we upload the particular image. On the other hand, if the image source is from a different site and you have permission to use it, you can use the div align tag to align the image manually to our preferences. All you have to do is to wrap the image source codes with the div align tags like this:
<div align="center">The Image Source code</div>
All your images will be aligned to the center of your post. It can also be aligned to the left or right.
Similarly, if you want your embedded videos to be aligned to the center of your post, you too can use the same tags like the example below.
<div align="center">
<object width="340" height="285"><param name="movie" value="http://www.youtube.com/v/RexXDDA8RoI&hl=en_US&fs=1&rel=0&border=1"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/RexXDDA8RoI&hl=en_US&fs=1&rel=0&border=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="340" height="285"></embed></object></div>
This will result in your videos sitting right at the center.
Nice and neat. While you are here, enjoy the video. It never cease to amaze me as to how in 1928, when computers and CGI software have not been invented yet, these guys can come up with such lively cartoons.
Related posts:
- How To Add A Frame Around YouTube Videos In WordPress Something I did out of boredom today. Saw lots of blogs embedding their Youtube videos in the same boring style, so I thought it would be nice if we were to add a nice frame around those videos. First I downloaded an image of a picture frame and re-sized...
- Align Image In Post WordPress 2.7 More than a year ago, I posted the stylesheet codes for aligning images in your WordPress posts. Times have changed and WordPress has added many new advanced features. One of them is the ability to align your images perfectly when you insert your image in your post editor. The only...
- Embedding Videos In your Wordpress Blog – for noobs. I remembered when I first started blogging in Wordpress after spending a year with Blogger, the task of embedding a Video in my post was so daunting. It was still Wordpress 1.5 back then and trying to embed a video or a sound file was a terrifying experience for me....
- How To Create A Beautiful Background For Your WordPress Post Now this is purely for pleasure only, but maybe on some occasions it could be useful. Having a beautiful background for certain post will bring out the mood for in your reader if you are targeting certain issues or maybe writing something romantic. For example if you are writing...
- How To Create A WordPress Child Theme As far as I know, a child theme is something that can only be created if you are using WordPress. Though you save yourself loads of time not having to learn php, you do have to master CSS or at least have a good understanding of it. However, learning CSS...












{ 2 trackbacks }
{ 1 comment… read it below or add one }
i usually use if I want the video centered. Before, I get really frustrated when the video frame is not where i intended it to be.