FCK Editor Plugin for InsertNode

zewa - March 7, 2009 - 15:02
Project:InsertNode
Version:6.x-1.x-dev
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:needs review
Description

Hi all ...

As this cool module now fullfills everything i need, but should allow smarter
input, for lets say Wysiwyg Editors like FCK here comes a small snippet that extends
your Toolbar with an InsertNode button.

Simply extract the attached zip file into your FCKEditor/plugins folder.

then open up the fckeditor.config.js file and add

FCKConfig.Plugins.Add( 'insertnode', 'en,pl' ) ;

next to the other plugin addings.
After this specify the icon to show up in your desired toolbar.
mine looks something like this

['Link','Unlink','LinkToNode','LinkToMenu','Anchor', 'InsertNode'],

Greetings
Zewa

AttachmentSize
insertnode.zip3.41 KB

#1

AlexisWilke - March 8, 2009 - 08:41

Hi Zewa,

I tried to see whether it would work for me and it failed. I had to change the oEditor with FCK instead. Which version of FCKeditor are you using?

Thank you.
Alexis Wilke

(EDIT)
P.S.
I added my version on my site here: http://linux.m2osw.com/insert_node
We cannot actually add .tar.gz files to the CVS so I cannot put that in the InsertNode project directly.
I will add your version now.

#2

zewa - March 8, 2009 - 11:01

I use version 2.6.3 of FCKEditor.

the only thing left unclear for me is, which ID the FCKEditor gets from Drupal by default.
couldn't find the position, but a search of the files gave me that 'oFCK_1' is mine.

Can you tell me exactly what didnt work?
you mean the first line of InsertNodeCommandText?

var oEditor = FCKeditorAPI.GetInstance('oFCK_1') ;

Shoot up Firebug and debug that JS stuff so we should be able to find the buggy position.

I built this plugin using standard tutorials, so by gods sake it should work properly :)

Greetings
Zewa

#3

AlexisWilke - March 8, 2009 - 21:10

Zewa,

Yes. That line returned nothing (null) Then using oEditor would obviously fail.

Using FCK works however. I looked at some of the other plugins to see what they were doing and they use FCK instead.

Now, I think it would be really great if we could have a dialog with different widgets like drop-downs with "normal", "collapsible", "collapsed". Then a set of check boxes for "title", "teaser", "body", "more", "comments".

And we should be able to steal the linktonode code so users can select the node easily.

Thank you.
Alexis Wilke

#4

zewa - March 8, 2009 - 22:44

you're absolutely right ...

that would push the usability extremely.
I'll throw some looks at the linktonode module maybe it's not so hard to append it.

Greetings
Zewa

 
 

Drupal is a registered trademark of Dries Buytaert.