Hi all ,
I had a task where we have to remove some specified toolbar items dynamically for the particular user group, So here is the link where I have some hack, to add or remove toolbar items in FCKeditor dynamically.
http://mehmoodbluffs.blogspot.com/searc ... /Fckeditor
regards,
Mehmood
Tue, 02/06/2007 - 23:26
#1
RE: Dynamiclly Add and Remove FCK Toolbar ite
Wouldn't it be easier to set up two toolbar configs in the fckconfig.js file and then when you create the editor choose the right one? or use different custom config.js files for each group of users?
RE: Dynamiclly Add and Remove FCK Toolbar ite
Hope this helps and also thanks for your comments Alfonso.
regards,
Mehmood
RE: Dynamiclly Add and Remove FCK Toolbar ite
My app supports bibliographies (among other similar types of data)
The first level, font formatting, is used for author's names etc. where I need special characters only (plus the basics like Source) -- and where I especially do not want to support anything to do with paragraphs.
The second, text formatting, supports changing the appearance of the entered text, typically for titles: bold, italics, super and subscripts, etc. plus everything from the first. Again the assumption is. that the character string is a single line (even if wrapped)
The third, paragraph formatting, adds support for lists, indenting, etc. useful for annotations.
This covers most situations, although some other apps of mine do have a special configuration for a specific need.
So I have been able to avoid managing switches on every possible combination -- what I would like to see, however, is a way to preserve these toolbar definitions in an outside file that gets included into the config file so I don't have to copy and paste with every new release. That would be a great help.
Reg
RE: Dynamiclly Add and Remove FCK Toolbar ite
Yup there is a possibility to load your own custom configurations files.
check out this link http://wiki.fckeditor.net/Developer%27s ... tions_File
Hope this helps. If u need toolbars of various combinations,then it's better to remove the tool bar items dynamically as described in the first post.
regards,
Mehmood
RE: Dynamiclly Add and Remove FCK Toolbar ite
Instead of changing the code to remove toolbar items it's better to use one or a combination of the following patches to create all the toolbar items in your configuration file:
https://sourceforge.net/tracker/index.p ... tid=543655
https://sourceforge.net/tracker/index.p ... tid=543655
https://sourceforge.net/tracker/index.p ... tid=543655
https://sourceforge.net/tracker/index.p ... tid=543655
RE: Dynamiclly Add and Remove FCK Toolbar items
Thanks for the tip about the CustomConfiguration file -- I had overlooked that feature, but now I am using it and it works just fine.
Reg
RE: Dynamiclly Add and Remove FCK Toolbar ite
Thanks for the comments , I liked the JSON serializing of the toolbarsets and I have planned to implement that.Then I have some features to implement in the Image browser too,like we have some private folders and shared folders so is there any plugin available to move the files between folders?? or I have to implement that??.That would be a great help for me , thanks in advance.
regards,
Mehmood
RE: Dynamiclly Add and Remove FCK Toolbar ite
RE: Dynamiclly Add and Remove FCK Toolbar ite
Maybe just disabling them is an option?
Try my 'HOWTO - disable toolbar buttons': https://sourceforge.net/forum/forum.php ... _id=257180