dark        
Tony Ponce blog header photo
Tony Ponce's c-blog
Fronts 2044Posts 0Blogs 64Following 0Followers 135


 
 

LONG BLOG

C Blog style and formatting tips

   0


Giving your audience a short break from reading to enjoy an entertaining YouTube clip is always a nice treat. Instead of directing them off-site via a link, embed the clip right in the body of your blog. Embedding video is only slightly more complicated than uploading images, but it causes more problems for users than any other function I've already discussed.

Go to YouTube and find a clip that you'd like to share. Below the video player, there should be a button labeled "Embed." Click that and copy the HTML code that appears (sometimes, you'll get a notice that embedding had been disabled, so beware). Below the image uploader on your editing window, you'll notice a box labeled "Embed videos." Paste your code right in there and upload. The HTML will be converted into BBCode which can be easily added to your post as such:



Wait! You're not finished! This embed suffers the same problem as an off-site hosted image. Many web videos are 640px wide and must be resized to avoid cropping. Here's the original embed code for the Panty & Stocking clip above:

<iframe title="YouTube video player" width="640" height="390" src="http://www.youtube.com/embed/nEpy0znKHWs" frameborder="0" allowfullscreen></iframe>

We need to change the width and height values. I like all my videos to be 620 x 378 because it'll display widescreen video accurately and 4:3 video with black bars on the side as on a TV. So I alter the numbers:

<iframe title="YouTube video player" width="620" height="378" src="http://www.youtube.com/embed/nEpy0znKHWs" frameborder="0" allowfullscreen></iframe>

When I upload the new code, I get this:



Compare this to the previous embed. It's a subtle but clear difference.

Can you embed video from sites other than YouTube? As long as the video in question has HTML embed code, of course you can! Here's a video from GameTrailers:



The embed code from some sites can be quite long. Your quest is to find every height and width value and change them accordingly. Missing a single value may or may not screw up your embed, but as mama always said, it's better to be safe than sorry.

Can you embed media other than video, like a music player? Hell yes, you can! The Zero Cool cats do it all the time! As long as the associated media has embed code, you are in the clear:



--------------------

If you are still with me, congratulations! Again, let me know if you have further questions or if you find error with any of my instructions. Now get writing!

Login to vote this up!

LOOK WHO CAME:


Tony Ponce   
Chris Hovermale   7
Zwoooosh   1
LawofThermalDynamics   1
Nihil   1
Kaggen   1
iconstyle   1
ThaJinx   1
Just1n   1
Stephen Turner   1
Phoust   1
knutaf   1
Jed Whitaker   1
Luckrequired   1
Dean Marshall   1
Starmac   1
Portable Nerd   1
Lord Death of Murder Mountain   1
JJJEnigma   1
Scissors   1
Ben Davis   1
DyneSil   1
M Randy   1
Daxelman   1
Alasdair Duncan   1
Tony Ponce   1
Alanar   1
CelicaCrazed   1
Kevin McClusky   1
Tubatic   1
Darren Nakamura   1
manasteel88   1
Kraid   1
Uber Mashu   1
P-Dude   1
Nic128   1
Occams   1
Elsa   1
SuperMonk4Ever   1
EdgyDude   1
CarlCastello   1
TezElNerdo   1


 
 

  0 COMMENTS

Please login (or) make a quick account (free)
to view and post comments.



 Login with Twitter

 Login with Dtoid

Three day old threads are only visible to verified humans - this helps our small community management team stay on top of spam

Sorry for the extra step!

 

About Tony Ponceone of us since 12:40 AM on 09.09.2007

(Decommissioned) Super Fighting Robot