Is there a way to customize the links popup windows to include in the Advanced properties the possibility to insert/edit the meta tag "rel" in a <a href...> tag ?

Thank you in advance.

Comments

Jorrit’s picture

Status: Active » Closed (fixed)

This is something that you should request at www.fckeditor.net.

ar-jan’s picture

Title: meta link "rel" » meta link "rel" tags in FCKeditor possible?
Version: 6.x-1.3-beta » 6.x-1.3-rc1
Status: Closed (fixed) » Active

Although in the end it should be added/supported by fckeditor, it appears to be possible to customize this. Based on some readings I have been trying to get it to work, but since I don't really know how it all works, without success (the field does not show up in the FCK dialog).

So I would like to ask if anyone has customized FCKeditor plugin to include custom rel= tags, and how they did it.

The following posts seem relevant:
http://www.contrexx.com/forum/showthread.php?s=0f9df91b822e2b617e8978dc7... (If you download the zip, check the lines they added, GetE('txtAttRelation').value = oLink.rel ;, etcetera.
http://www.fckeditor.net/forums/viewtopic.php?f=6&t=8903
http://www.fckeditor.net/forums/viewtopic.php?f=6&t=7727

wwalc’s picture

Status: Active » Closed (fixed)

All you need to do is to modify those two files:

modules\fckeditor\fckeditor\editor\dialog\fck_link.html
modules\fckeditor\fckeditor\editor\dialog\fck_link\fck_link.js

If you haven't done it yet, take a look at http://dev.fckeditor.net and search if anyone asked for such a new feature already.
If not, then that's the right place for this feature request. It would be nice to report it there, because CKEditor 3.0 is in production and the more new reasonable feature requests, the better.

ar-jan’s picture

Title: meta link "rel" tags in FCKeditor possible? » Howto have meta link "rel" tags in FCKeditor
Status: Closed (fixed) » Fixed

Alright, I thought I didn't get it to work, but when I checked back it was actually working, so this was probably a cache problem. Here's what I did to get an option for rel="external", which I use together with this javascript code to open them in a new window.

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 />

							<select id="txtAttRelation" style="WIDTH: 100%">
								<option value="" selected></option>
								<option value="external">&lt;External&gt;</option>
							</select>

						</td>

					</tr>

				</table>

If you want the option located in the Advanced tab of the link dialog popup, you can put this at the very bottom, right after the table that contains the txtAttStyle option.
You can of course also add another option with the value for nofollow. You could also make it a text field to leave users free to put whatever rel tag in there.

Also add the name of the option in the language files in fckeditor/fckeditor/editor/lang > your language file.
In "// General Dialogs Labels", put something like:
DlgGenRel : "Rel-tag",

Hope this helps. Will look if I should make a feature request for FCKeditor.

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.