How to insert videos from local server in WordPress post
The use of videos is a way to make your site more attractive. WordPress 2.7 offers an easy way to use video clips from sites like YouTube or Metacafe in your blog. You just have to use the function Insert / edit embedded media in the visual mode of the wordpress post editor. But what happens if you want to use videos uploaded on your local server?
Today I decided to add videos to some of my posts that are uploaded on my local server but I found that it is not as easy as it looks. The problem was that when I add an video into post it doesn’t appears where it must be. Instead of this there appears only a white spot with the same size as the missing video. Later I realized that I need Flash plugin in order to see my videos. If you have the same problem than do the following:
Now the first thing you have to do is to install the flash video plugin in your blog. Leave it with the default settings (later I changed only the width and height of the video window) . Then convert your video to FLV format with this program. Using of videos from sites like YouTube is even easier because there are programs that convert the downloaded videos in FLV format immediately. In order to upload the clips you have to create folder on the local server where they will be stored. You can use any name for that folder. When it is done go to post editor and swtich to HTML mode. Then insert the following code to your post:
[flashvideo file=http://yoursite.com/wp-content/uploads/video/yourfile.flv /]
where http://yoursite.com is the URL of your web site and yourfile.flv is the name of your video.
For this example I created the folder video in my WordPress installation directory where to put my clips. But you can use any place for that folder even on a remote server. The plugin only needs the full URL of your video clips.
OK.Now the video is in your post and you can watch it. But there is one more thing to do. It’s called poster frame (or image) and it replaces the background color of the player (the default background color is black) with picture captured from the video clip. You can do this by playing the video as it is in AVI format in BS player, use the “P” key to capture frame and then save the captured frame in jpg format.
If you want to show a poster frame of your clip you have to add the following lines to the previously added code and make it looks like this:
[flashvideo file=http://yoursite.com/wp-content/uploads/video/yourfile.flv / ;image=http://yoursite.com/wp-content/uploads/poster-frames/yourfile.jpg /]
Here is created new folder named poster-frames where the poster frames are stored. Of course you may use any name that you like.
Note: the file names and paths in your code must be the same as they are on your server.

May 13th, 2009 at 14:00
Good work! Thank you very much! I always wanted to write in my blog something like that. Can I take part of your post to my blog? Of course, I will add backlink?
July 22nd, 2009 at 1:57
Great post! I’ll subscribe right now wth my feedreader software!