WordPress plugin: Youtuber

By default, embedded YouTube videos are 425 pixels wide, which is wider than the content column on Choking on Popcorn. To be able to easily resize and add cool videos to that site I copy-pasted together a very basic plugin for WordPress. It allows you to simply use something like [youtube ]xxxxxxxxx[/youtube] to embed the video. The ‘xxxxxxxxx’ bit needs to be replaced with the actual video’s ID of course. I know there are tons of plugins that do similar things and are vastly superior, but this one suits my needs perfectly.
The output is valid XHTML, and you can adjust the display size by editing the plugin a bit. The entire thing is only a few lines so you’ll have no trouble finding the dimensions in the code. Simply replace the numbers 425 (width) and 350 (height) with numbers that fit your site’s layout. Simply use the options panel under Options -> Youtuber.
Feel free to download it and play around with it a bit. If you make improvements or can think of a cooler name for the plugin, please let me know.
Installation
- Download the zip file and unpack the file inside.
- Upload this file to the wp-content/plugins folder on your server.
- Activate it on WordPress’s ‘plugins’ tab.
To embed a video using the plugin, follow these steps:
- Find the video on YouTube.
- Extract the ID fromthe video page url. These look something like: http://youtube.com/watch?v=Krhl2o_uwdc. The bit I put in bold type is the ID.
- Type [youtube ]Krhl2o_uwdc[/youtube] anywhere in your post. Leave out the space in the first tag.
- Save and publish the post.
To change the display resolution for the videos:
Open youtuber.php in a text editor (I use Notepad++)Find the numbers 425 and 350.Replace these numbers with your preferred display dimensions. The control bar underneath the video is about 20 pixels high, so the height should ideally be 3/4 of the width plus 20 pixels.Save the file and (re)upload to your plugins folder.- Go to Options -> Youtuber and type in the values that work for your blog.
History
- Version 1.3 was the first to be hosted on WordPress.org, and released under GPL.
- Version 1.2 adds better default values, case insensitive tags, and fixes an issue with WPMU.
- Version 1.1 adds a basic options panel.
- Version 1.0 was the initial release.


This is the personal blog of Roy Tanck, designer, geek, entrepreneur and WordPress enthusiast. It's also the home of projects like 
Nice plugin! This is what i am looking for. Thank you.
- got it from wordpress.org -
Comment by JP — April 16, 2009 @ 8:11 pm
cool guys! your posts are great!
The Joomla Experts
Comment by Joomla Experts — July 10, 2009 @ 8:17 pm
youtuser
Comment by Ellison Rocks — July 11, 2009 @ 7:17 pm
You have some great plugins on your post. Your insight and expertise would be a welcome addition to our new community, i hope you will consider joining, and thanks for sharing!
Comment by free plugins — February 22, 2010 @ 11:26 pm
I would work with your plugin and add some new features. Can we talk via email?
Comment by Juan Sebastián Echeverry — March 3, 2010 @ 3:30 pm
Hi Juan, yes we can. I’ll drop you an email right away.
Comment by Roy — March 3, 2010 @ 5:11 pm
Are you still seeing comments here? Guess I’ll find out.
Thanks for the plug-in. It worked great for even a non-techie like me. Is there a way to NOT include the related videos??
Thanks.
Comment by Sally — May 25, 2010 @ 12:28 am
Hi Sally. I’m afraid not. YouTube puts them there, and afaik you can’t get rid of them.
Comment by Roy — May 26, 2010 @ 10:25 am
Thanks a bunch. This is simply the best youtube for WP I have come across. Most of the others are simply too complicated and does not work.
Excellent work.
Comment by Bill — June 3, 2010 @ 7:33 pm
It’s not working with WordPress 3.0 ;(
Comment by Tobias — June 18, 2010 @ 3:44 pm
Hi,
works great, very easy and absolut valid xhtml.
Thx for that!
Frank
Comment by Frank — June 21, 2010 @ 1:03 pm
btw… iam using WP 3.0 and it works perfect!
Take a look at http://www.schachplatz.de/rundgang-im-dox-in-prag/
Greetz
Frank
Comment by Frank — June 21, 2010 @ 1:04 pm
i hope, the video is shown also in RSS-Feeds. I cant try this at the moment….
I know other plugins, who dont shows the videos in RSS.
Will see……
Frank
Comment by Frank — June 21, 2010 @ 3:12 pm
I used this type of plug-in for phpbb and vbulletin. My search ends here. Thank you very much for the plug-in.
Comment by Desi Colours — July 3, 2010 @ 6:18 pm
This gives error. After i instal this, if i disable any plugin, i get this error:
Warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, ‘youtuber_uninstall’ was given in /home/public_html/wp-includes/plugin.php on line 395
Comment by Owdy — September 4, 2010 @ 10:41 pm
http://wordpress.stackexchange.com/questions/1047/when-i-try-to-de-activate-any-plugin-it-gives-error-warning-call-user-func-arra
Comment by Owdy — September 4, 2010 @ 10:43 pm
Hi Owdy. I’ve forwarded your bug report to sebaxtian, who’s currently the lead developer for Youtuber. Thanks,
Comment by Roy — September 9, 2010 @ 9:57 am
Thank you for the plugin. I’m testing it out right now and it seems very simple to use. Continued Success!
Comment by JAWAR — November 27, 2010 @ 7:05 pm
I’m getting xhtml errors as:
- there is no attribute “wmode”
…access” value=”always” />…
- there is no attribute “width”
…=”always” allowfullscreen=”true” width=”425″ height=”355″>
- there is no attribute “height”
…=”always” allowfullscreen=”true” width=”425″ height=”355″>
- element “embed” undefined
…=”always” allowfullscreen=”true” width=”425″ height=”355″>
Comment by openredes — February 9, 2011 @ 3:56 pm
Hola openredes
We are using the HTML code youtube gives to embed a video, and it uses the tag ‘embed’ which isn’t part of the standardized version of HTML. There is a way to solve this situation called The Satay Method (search it on Google) but to apply it we have to modify the flash code of the youtube video player.
If you know a way to embed a Youtube video without using the ‘embed’ tag I will like to know about it, so we can modify Youtuber.
Comment by sebaxtian — February 10, 2011 @ 1:22 pm
hi,
the youtuber doesnt work on my new site. It is WordPress 5.1. Have an idee of why?
Comment by Peter — February 24, 2011 @ 10:08 pm
Hi again. On my site cmsone.se/jazz it now works in the form [YouTube]fulladdress[/YouTube] but not with id. But that’s alright with me. Thanks for great plugin.
Comment by Peter — March 2, 2011 @ 7:59 am
Wow Great Youtube Plugin – So much great stuff
Comment by Atif — April 24, 2011 @ 12:48 pm
I would like to embed videos in different sizes into my webpages. How can I overwrite the youtuber standard settings (height and width) respectively set the size for every embeded video ?
Thx
Comment by Thomas´H — June 13, 2012 @ 2:35 pm
I don’t think there’s an option to do that right now. The whole point is to keep things easy and make it easy to set new dimensions globally when you switch theme. You could ask Sebaxtian though, he maintains this plugin now.
Comment by Roy — July 4, 2012 @ 8:29 pm