Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We're retiring the forums!

The SilverStripe forums have passed their heyday. They'll stick around, but will be read only. We'd encourage you to get involved in the community via the following channels instead:

Content Editor Discussions /

Forum for content editors and CMS users.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

Insert Link problems

Go to End

2 Posts   1381 Views


Community Member, 2 Posts

27 March 2014 at 12:33am

Hi there,

i really don't know if this is a real problem, or maybe it's just me.

The "Insert Link"-Button in the HTML-Editor doesn't work as expected in all Versions of SS3 i maintain (latest is 3.1.3).
Seems like it is rendered "disabled" due to some test case in "framework/thirdparty/tinymce_ssbuttons/editor_plugin_src.js" line 56-59:

ed.onNodeChange.add(function(ed, cm, n, co) {
cm.setDisabled('sslink', co && n.nodeName != 'A');
cm.setActive('sslink', n.nodeName == 'A' && !;

When i disable this code everything works as expected. I.e. i can insert links in the editor.
Since i am by no account a JS expert, let alone this editor thingie, i can only vaguely guess how the nodeName 'A' is created, passed and so on.
One can find (almost) the same code in the "official" advlink-plugin in the TinyMCE plugin directory.

Since this would be such an obvious bug it is well possible that this is some kind of pebcak.

Has anyone expirienced similar problems?

Groetjes, niels


Community Member, 2 Posts

31 March 2014 at 11:45pm

Edited: 01/04/2014 1:17am


I fiddled around this problem in the last few days and it still persists.
When I create a link in plain ol' HTML and point the cursor in the editor over it, the "Insert Link"-Button get 's rendered "mceButtonEnabled".
When I leave the link area the button get 's rendered "mceButtonDisabled" again.
That would be a perfectly sane behaviour for the unlink button.
As far as i can see the sslink code is all about the insert link function so the above mentioned code would be at least superflous.

It still bugs me that no one seems to experience a similar behaviour or could at least tell me: "No, everything works fine. Go check your head."

Groetjes, niels

After doing something i usually avoid to do, i.e. reading the documentation, i 've found out that the user is expected to mark the text segment he wants to turn into a link text.
I will have to contemplate a while about this technique to decide if it is extremely witty or just plain stupid.