-
Notifications
You must be signed in to change notification settings - Fork 253
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Video plugin #133
Comments
I too am having this issue |
how i can add new plugins? it´s imposible or what? |
Hi folks, just had this issue and it seems like the API changed and video.js hasn't been updated since? Simple fix, though, just change the first few lines of the script from/to: (function($)
{
$.Redactor.prototype.video = function()
{ if (!RedactorPlugins) var RedactorPlugins = {};
(function($)
{
RedactorPlugins.video = function()
{ @koraks: nothing is impossible, pal ;^) |
Excellent fix, thanks! |
For anyone else who comes across this, the exact same fix needs to be applied to any non-default plugins that you download from the redactor website. They will NOT work by default. I can see the video button now, but I still can't insert a video without an error. |
is it not possible to use the video plugin now at all? |
Hi! I found the modified JS files for audio/video plugins here https://github.com/kyan/redactor-plugins Also, mb it will be useful, i use .sanitize method for showing my Articles. This method cuts iframe tag what needed for video. You may change tags for .sanitize in config/application.rb:
All tags except iframe are the same as in sanitizer.rb |
@robot-den Thank you so much. I can see the videos appearing now :) |
I have used this and it worked for me... |
I've added video plugin manually but it doesn't being showed
//= require redactor-rails
//= require redactor-rails/video
config.js
$(document).ready(
function(){
var csrf_token = $('meta[name=csrf-token]').attr('content');
var csrf_param = $('meta[name=csrf-param]').attr('content');
var params;
if (csrf_param !== undefined && csrf_token !== undefined) {
params = csrf_param + "=" + encodeURIComponent(csrf_token);
}
$('.redactor').redactor(
{ "imageUpload":"/redactor_rails/pictures?" + params,
"imageGetJson":"/redactor_rails/pictures",
"fileUpload":"/redactor_rails/documents?" + params,
"fileGetJson":"/redactor_rails/documents",
"path":"/assets/redactor-rails",
"css":"style.css",
"plugins": ['video']}
);
});
The text was updated successfully, but these errors were encountered: