Questions? 866-530-4804.
Welcome Internet Explorer user!
It looks like you are using IE6. CoTradeCo.com works fine in IE6 but doesn't look as nice. Consider upgrading to IE8, Chrome, Safari, or Firefox.
For more information on why visit BrowseHappy.com.

Subscribe Digital Life »Tips, tricks, and advice
Computer Specifics: How to Embed video in your Wordpress blog (without a plugin)
beingzoe over 1 year ago | 4 responses    

Recently, UK Case Lady asked me how to embed video in a Wordpress blog.

For the record I do not have a Wordpress blog and am relying on the embedded video above and a few quick glances at some other resources for my answer. Therefore I am unable to test this myself, but hopefully the UK Case Lady can jump back in. When I have more time I will look more deeply into this to give a more thorough response that includes how to do embed content with or without a plugin and with the rich editor.

The problem is the rich visual editor referred to elsewhere as a WYSIWYG or Rich text editor in Wordpress. By turning off the rich text editor you can embed video without any problems.

Before logging in to the administrative interface of your Wordpress blog, there is a checkbox option that says, “Use the rich visual editor when writing.” Uncheck that option and you’ll be able to paste embedded content directly into your blog.

To understand the problem you need to know what a rich visual editor is. When you view a web page your browser retrieves the page and interprets the HTML and Javascript code into something visual and friendly that does something. If you have never done it, right click (option-click) on a web page in your browser and choose “view source” or “view page source.” This will open another window displaying the code that is required to render the visual version of the page in the browser.

Rich visual editors or WYSIWYG editors allow an individual to skip the process of writing any funny codes to format their page or post into HTML.

Unfortunately, WYSIWYG style editors, especially those that operate on a web page, tend to eat up, destroy, and even intentionally remove actual HTML that might be entered in the visual editor. This appears to be exactly what is happening in Wordpress blogs. When you paste in the embed code from YouTube (or any other embeddable content or widget that uses either the “embed” tag or the “object” tag (html tags) they are stripped out or otherwise reformatted/rewritten so as to make them non-functional when the Wordpress blog post is viewed.

So the solution is to disable the WYSIWYG editor while posting and editing blogs that require embedded content, such as a YouTube video.

The downside is that when you disable the editor you will now have to manually code/format your post. In Wordpress, much like at CoTradeCo, there is still an editing toolbar that will add the “code” in for you, but you will not be able to see the formatting as you do it, only the “code” that represents the formatting.

You can turn visual editing back on as long as you do not edit any posts with embedded content. Just remember to disable visual editing if you need to post new embedded content or a post with embedded content.

And that is how you can get around not being able to install a plugin. Apparently there are several plugins that allow for pasting embedded content into the visual editor without “eating it up.” But I’ll try to talk about that in another post or in the comments here another time.

Hope this helps you out.

More Digital Life discussions
« Older-er
What is Second Life? And why should you care?
What is Second Life? And why should you care?
‹ Older
CSS relative absolute positioning
CSS relative absolute positioning
Newer ›
Mashups, widgets and your web presence
Mashups, widgets and your web presence
Newer-er »
Marine with Laptop on top of the Westin
Marine with Laptop on top of the Westin
beingzoe
ARGHHH! Just posting about embedding video is making the embed not work!

NOTE: There is supposed to be a video embedded in this post, but perhaps I’ve tempted fate. The video is not embedding, hmmm.

Anyway, you can view the video at YouTube here

 
beingzoe

Oh sure, and then I post a comment and it magically appears. I hate computers!

 
UK Case Lady

Thanks for doing the research Zoe… but I did actually end up installing a plugin :). Disabling the Rich Text editor works perfectly for blogs that are hosted by WordPress, but not ones that are hosted by an outside source (like mine is). It seems like there should be an easier fix than having to install a plugin, but I couldn’t find it and to be totally honest I am not very tech-savy (I can find solutions online and apply them, but I don’t always understand why they work).

 
beingzoe

I tried.

The easier fix would be for Wordpress to simply ignore HTML pasted into the visual editor, which they must have left out for some good reason.

For example, here at CoTradeCo we do not allow the general public to use any HTML directly in their posts for security reasons. That is why you have to paste the embed code into a special field that we can match against known (e.g. safe) embeddable content providers.

Though we really should implement a visual editor.

Could you post a link to the Wordpress plugin you used and how you got it installed at your ISP? It would probably help people out who stumble on this post in the future.

 

Post your response

Already have a SPOT? SIGN IN to post a response.
Otherwise, enter your info below!

Do not change the following three fields.

Required. No HTML. Textile syntax only.
What is your take on this post? Share it with the community.

 

If you have never posted here before...

Community mail


We take privacy and spam seriously and will ALWAYS protect your information.
By commenting, you accept the CoTradeCo terms of use.

More community & discussion



Got something to say?
Start a new discussion





Find related info on CoTradeCo

Also see all community blog discussions or our resource library.









Also visit our partner community TopSportsBets.com

© 2007-2009 CoTradeCo, Coachella Valley Packaging, & Coachella Valley Trading Company
are part of the Shorebird Corporation

Community content is all rights reserved © by the contibutor of that content granting
CoTradeCo some limited non-exclusive usage rights, see our policies.