Opened 18 years ago
Closed 18 years ago
#533 closed Bug (invalid)
ProtectedTags not working for custom FontFormats tag
Reported by: | dc | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | General | Version: | |
Keywords: | Cc: |
Description
I added a custom tag to the FCKConfig.FontFormats list, named it in the language file, added it to the fckeditorcode_ie.js and fckeditorcode_gecko.js files and added it to the FCKConfig.ProtectedTags list. When using the Format dropdown to change a selected portion of text to custom format eveything seems to work fine until the document is saved or Source view is toggled. At that point the text disappears completely. Using firebug, I found a problem with the element inserted by FCKeditor.
Before changing the selected text to the custom format the element was:
<p> test text </p>
After the formatting change the element was:
<<toc> _moz_dirty=""> test text </<toc>>
When I switch to Source view the element disappears. I assume this happened because the element is malformed.
When I edited the tag in firebug to look like:
<toc _moz_dirty=""> test text </toc>
And toggled Source view it worked properly. I tested this in both Firefox2 and IE7.
Change History (3)
comment:1 Changed 18 years ago by
comment:2 Changed 18 years ago by
I have noticed that you need to have a p tag in the content, otherwise in source view tags by themselves disappear. (in firefox)
e.g. in source view enter: <customtag/> toggle source back and forth and it will disappear.
This seems to be fixed in the nightly demo however: http://www.fckeditor.net/nightly/fckeditor/_samples/default.html
comment:3 Changed 18 years ago by
Resolution: | → invalid |
---|---|
Status: | new → closed |
It is not possible to define custom tags in the FontFormats list. You may remove some of those in the list, but not add your custom ones. This is an intrinsic browser limitation.
The ProtectedTags line in fckconfig.js is:
And the FontFormats line is: