2011-08-10 14:17:16Posting YouTube videos in our WYSIWYG system
John Cook

john@skepticalscience...
124.177.173.40

Just doing some tests with posting YouTube into the SkS WYSIWYG system:

2011-08-10 14:28:50
Daniel Bailey
Daniel Bailey
yooper49855@hotmail...
97.83.150.37

Why not use the regular youtube embed code that comes with each video?  You just change the sizes accordingly & voila!  Bob's your uncle...

2011-08-10 14:37:39That's what I'm trying to do
John Cook

john@skepticalscience...
124.177.173.40

But the WYSIWYG system filters it out. I've been cheating by copying and pasting straight into the raw HTML but that's not a solution for the rest of the SkSers.

2011-08-10 14:40:51Okay, made some tweaks to my code and now seems to work
John Cook

john@skepticalscience...
124.177.173.40

The technique to add YouTubes seems to be:

  1. Click the HTML icon
  2. Copy and paste the YouTube embed code
  3. Click Update to close the HTML Source Editor window

Bingo, YouTube added. This work for others?

2011-08-10 16:44:49
Dikran Marsupial
Gavin Cawley
gcc@cmp.uea.ac...
139.222.14.107

yes, works for me.

2011-08-10 16:52:38
Daniel Bailey
Daniel Bailey
yooper49855@hotmail...
97.83.150.37

I just right-click on the desired youtube video, select the "copy embed html" option, right-click where I want to put the embedded video and select the paste option.  Then change the default size to 500 by 305 in both places.  Like this:

<object style="height: 305px; width: 500px"><param name="movie" value="http://www.youtube.com/v/XsR0DeY7f1g?version=3"><param name="allowFullScreen" value="true"><param name="allowScriptAccess" value="always"><embed src="http://www.youtube.com/v/XsR0DeY7f1g?version=3" type="application/x-shockwave-flash" allowfullscreen="true" allowScriptAccess="always" width="500" height="305"></object>

2011-08-10 16:52:51You do have to edit & save it for the code to get conjugated, like this
Daniel Bailey
Daniel Bailey
yooper49855@hotmail...
97.83.150.37

2011-08-10 17:44:08test
John Cook

john@skepticalscience...
124.177.173.40

2011-08-10 17:45:30Ah so the right click code is different to the code you get from the YouTube page
John Cook

john@skepticalscience...
124.177.173.40

If you right click and select "Copy embed HTML", you get this <object></object> code. But if you're on the YouTube website and click the Share button below the video, you get <iframe></iframe> code. Either option now work.