Add rel field attribute in FCKEditor when editing link attribute

In fckeditor/fckeditor/editor/dialog/fck_link/fck_link.js, add the following:

[469] // Get Advances Attributes
GetE(‘txtAttRelation’).value = oLink.rel ;

[764] // Advances Attributes
SetAttribute( oLink, ‘rel’ , GetE(‘txtAttRelation’).value ) ;

And in fckeditor/fckeditor/editor/dialog/fck_link.html, add the following:


<table cellspacing=”0″ cellpadding=”0″ width=”100%” align=”center” border=”0″>
<tr>
<td>
<span fckLang=”DlgGenRel”>Relation</span><br />
<input id=”txtAttRelation” style=”WIDTH: 100%” type=”text” />
</td>
</tr>
</table>

In fckeditor/fckeditor/editor/lang > your language file.

In “// General Dialogs Labels”, put something like:
DlgGenRel : “Rel-tag”,

Source

One thought on “Add rel field attribute in FCKEditor when editing link attribute

  1. Hello,
    I’d like to thank you for this tutorial. Changed everything according to my needs (created the onmouseover and onclick events). Everything works! Thanks again and best of luck to you!

Leave a Reply

Your email address will not be published. Required fields are marked *