-
Re: How to Add a new Supported Video Site to the Rich Text Editor
Vishwa Jun 27, 2013 4:01 AM (in response to Vishwa)On Going through the documentation available in Jive ,I found the following page
Where it is mentioned that, we cannot add a Macro with the current release ? Is this valid for 6.0.2 and we cannot do any Customization regarding Macros?
Nicholas Lawrence : Could you please contact the documentation team to confirm this once for me ?
Regards
Vishwajeet
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
Vysali_Janardhanan Oct 29, 2013 3:37 AM (in response to Vishwa)Hi Vishwajeet,
Did you get any inputs in this?
We have a similar requirement and are looking around for a solution.
Regards,
Vysali
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
Vishwa Oct 29, 2013 4:07 AM (in response to Vysali_Janardhanan)Hi Vysali Janardhanan ,
Yes, we worked on this request and it is possible to add a new Video URL as a macro to the Rich Text Editor.
Here is what we had to do to implement this :-
1) Each video macro type is defined in Spring.xml file.
<bean id="customMacro" class="com.jivesoftware.community.renderer.macro.CustomMacro" scope="prototype">
<property name="videoUrlTemplate" value="http://customUrl.company.com/content/$(id)/" />
<property name="tagName" value="customName" />
<property name="enabled" value="true" />
<property name="useIFrame" value="true"/>
</bean>
Each macro bean definition is then added to the list of "renderPlugins" passed into the definition of the globalRenderManager.
To see what bean properties can be defined, review the source code of the VideoMacro java class.
2) Overlay resources/scripts/tiny_mce3/plugins/jivevideo/js/video.js
This javascript file contains an array of the allowed macros. The name of the video macro needs to be added here. Search for this snippet.
Define the Regular Expression and the Display name to be shown in the Front End in addition to the existing Macros.
So when the user enters the Valid Custom URL, the pattern is identified and Insert Video option is enabled.
There are regex definitions that define the valid video source url formats. A corresponding regex needs to be defined for the new video macro in the variable:
"customMacro": {
regexes:
[/customMacro.company.com\/content\/([0-9]+)\/([0-9]+)\/([0-9]+)/i],
displayName: "customMacro.company.com"
},
Once the valid Embed pattern is Selected and Inserted, the Video ID of the URL is extracted and Video is embedded in the Rich Text Editor.
Hope this helps in your task.Regards
Vishwajeet.
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
Vysali_Janardhanan Oct 29, 2013 7:03 AM (in response to Vishwa)Thank you Vishwajeet Joshi.
I was looking at this thread- How to Embed a Flash Video
Could you please elaborate how it might not help my case?
Regards,
Vysali.
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
Vishwa Oct 29, 2013 7:16 AM (in response to Vysali_Janardhanan)Hi Vysali,
It seems correct ,but do you want your users to every time work using Inser Raw HTML ?
Regards
Vishwajeet.
-
-
-
-
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
swaran Apr 24, 2014 10:29 AM (in response to Vishwa)Thanks for replying Vishwajeet.
Having problems finding allowed array in video.js. Can you also mention if this will be visible/controllable in admin panel?
Regards
Swaran
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
Vishwa Apr 25, 2014 1:07 AM (in response to swaran)Hi Swaran,
The "allowed " array can be found in the file, editor_plugin_src.js under jivevideo.
Regarding Admin Console Settings you can check Macros Section of the page, AdminConsle>>SPACES>>Settings>>Filters & macros
Regards
Vishwajeet.
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
swaran Apr 25, 2014 3:40 AM (in response to Vishwa)Hi Vishwajeet,
Have modified editor_plugin_src.js as you instructed. But i don't see it in Filters & Macros.
Did you make any additions to language files as well?
Thanks for your time.
Regards
Swaran
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
Vishwa Apr 25, 2014 4:55 AM (in response to swaran)Hi Swaran,
I am not sure how you have modified this ?
Did you do a WEB module Deployment to overlay the change in the javascript.?
Check if the Control is coming here by adding appropriate alerts in your overlaid js. Debugging this way is tedious but is the only way I know.
Have you properly defined the regular expression ?.
The Change also involves making changes to the Spring.xml in another plugin, as explained in my earlier response.
Regards
Vishwajeet.
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
rcherian Apr 25, 2014 12:33 PM (in response to Vishwa)Hi Vishwajeet,
Is the class name mentioned (com.jivesoftware.community.renderer.macro.CustomMacro ) in the step 1 a custom developed class?
Also noticed the changes done at .js files got removed after restart. Any idea why it is getting removed?
Thanks for the help.
Regards,
Regi
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
Vishwa Apr 27, 2014 10:47 PM (in response to rcherian)Hi Regi,
Yes , its a Custom Class that basically extends the BaseMacro and you can set the height- width of the video rendering window in RTE.
For JavaScript being removed on Restart, I would again like to know, how you are overlaying the javaScript ?
We did it by a deployment to the WebModule (.war) which most definitely involved application restart.
Regards
Vishwajeet.
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
rcherian Apr 29, 2014 1:08 PM (in response to Vishwa)Thanks Vishwajeet.
For testing purpose we have modified the core js files, but look like the files got regenreated again after restart
We will check the possibility to add this through custom war.
Thanks for the help
Regards,
Regi
-
-
-
-
-
-
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
swaran May 5, 2014 2:41 AM (in response to Vishwa)Hi Vishwajeet,
Can you please guide me to how to adding customMacro to globalRenderManager.
Please note instead of extending VideoMacro instead of BaseMacro as you defined.
Re
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
Vishwa May 5, 2014 2:36 AM (in response to swaran)Hi Swaran,
I am not sure what exactly are you looking for ?
Adding the Custom macro is by having a bean for it defined in the Spring.xml of the Plugin. I think, I have explained about it , in the thread above.
Regards
Vishwajeet.
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
swaran May 5, 2014 2:43 AM (in response to Vishwa)Hi Vishavjeet,
Above question arose due to our internal settings which is sorted now.
Please accept my sincere thanks for help in this thread.
Regard
Swaran
-
-
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
swaran Jun 13, 2014 7:37 AM (in response to Vishwa)Adding Customized Video to group tiles.
Did anyone go a step further and enable (non standard) videos in group tiles?
Regards
Sw
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
danil Jul 2, 2014 3:06 AM (in response to Vishwa)Hello everyone!!!!
Can somebody tell if there's an opportunity to add video to RTE without core rewriting , maybe by using some plugin or Jive apps,
I'm currently using Jive7 version.
Thanks!
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
Vishwa Jul 2, 2014 11:45 PM (in response to danil)Hi Danil Bogomolov , Swaran Singh,
I honestly dont have an answer, wheter Core ReWriting is a must or is there any other way.
We had to go for web-deployment as the changes to Javascript were not seen in the Plugin ? I am not aware if Swaran has managed to do this with only Plugin (putting Javascripts in the Plugin Structure )? Jive 7 does come with many new features but, I wonder whether it makes achieving this functionality any easy
Regards
Vishwajeet.
-
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
swaran Jul 2, 2014 5:51 AM (in response to Vishwa)Hi Danil
As Vihavjeet explained earlier this can be done with a plugin.
If you have any specific questions I will be happy to answer.
Regards
Swaran
-
Re: How to Add a new Supported Video Site to the Rich Text Editor
moesingh Jan 21, 2016 6:21 AM (in response to Vishwa)I didn't feel like overlaying so I used Javascript with Video.js to allow the user to enter embed code flv or a URL location for a video. Then it will create a div with the requisite data attributes so that it can use those data attributes to supply video.js enough information to show the video. It clones the video button and hides the original one. It also provides you with an option to go back to the original one (e.g. for google, dailymotion, etc.).
if anyone wants it let me know and i'll try to get permission to get it released here.