Attached is a patch that adds a button to TinyMCE 3 used with WYSIWYG API. It's based on the patch in #300643: Video Filter TinyMCE Plugin for 5.x. It's a very basic function right now, that only adds an input field. Later we could add width and height support here.

There's also some minor fixes that slipped in the patch, such as Godtube changed it's name to Tangled.

Instructions:

Apply the patch first. This creates a new folder called tinymce (not sure what the best name for that is though) and some files in there, and alters the module and inc files.
After that, unzip the images.zip archive and put it in the tinymce folder. I've used an icon from http://drupal.org/project/icon, since FamFam isn't GPL.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

XerraX’s picture

Status: Needs review » Needs work

doesnt work with TinyMCE 3.2.2, input stays blank if video filter button is enabled, just like the flash button:
http://drupal.org/node/379182#comment-1295726

TyraelTLK’s picture

subscribing

helmo’s picture

Status: Needs work » Needs review
FileSize
11.5 KB

Nice patch, although a patch against a clean version would have been nicer ;)

XerraX: It works fine with my TinyMCE 3.2.2.3, you tend to be suffering from a more general wysiwyg vs. TinyMCE problem.
I had a similar problem when I tested the combination a while back, but the solutions provided in #379182 are what solved it for me.

Attached is a clean patch against the latest Development snapshot

sirkitree’s picture

Version: 6.x-2.4 » 6.x-2.x-dev
FileSize
10.92 KB

Patch was a bit messy - cleaned it up properly and should now apply cleanly.

Please note that you still must download the images.zip to your video_filter/tinymce folder and extract it.

After the application of the patch, first add this filter to your desired input format (regular video_filter instructions) and then in WYSIWYG API settings (/admin/settings/wysiwyg/profile) Edit the input format that you enabled video_filter upon and under the 'Buttons and plugins' fieldset, check off the new 'Video Filter' option.

This patch saved me at least 4 hours of work, thank you very, very much!

helmo’s picture

To work properly with version 2.x of the wysiwyg API I had to add one line

--- video_filter.module (revision x)
+++ video_filter.module (working copy)
@@ -263,6 +263,7 @@
'path' => drupal_get_path('module', 'video_filter') . '/tinymce/editor_plugin.js',
'buttons' => array('videofilter' => t('Video Filter')),
'url' => 'http://drupal.org/project/video_filter',
+ 'load' => TRUE,
),
);
}

sirkitree’s picture

The location of the plugins has also changed to /sites/all/libraries

Update to patch.

mrfelton’s picture

With the latest code in -dev, applying this patch results in a file with a missing curly bracket, and hense, a fatal error. This patch includes the curly bracket!

mrfelton’s picture

Also, I found that in applying the patch, I end up with a completely broken wysiwyg editor (it fails to load)

helmo’s picture

Status: Needs review » Reviewed & tested by the community

Except for a straight forward merge conflict(due to a removed codec) in video_filter.codecs.inc the patch from #6 seems ok.

Make sure though that the files are placed in the tinymce/images tinymce/langs and tinymce/jscripts directories. This might be your problem mrfelton.

mrfelton’s picture

yup. That was it.

superfedya’s picture

Hello
How I can install this patch on virtualhosting like a Bluehost?
Thanks!

blackdog’s picture

Status: Reviewed & tested by the community » Fixed

Committed! Thanks people for reviews and patches!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.