Author |
Message |
bfnuke
Hangin' Around

Joined: Feb 01, 2006
Posts: 43
|
Posted:
Wed Feb 22, 2006 4:41 am |
|
I have had a couple occations where I wanted to remove the formatting that I put in for something, but there is no "blank" selection for any of the drop downs in the editor. Anyone already "fixed" this? |
|
|
|
 |
Guardian2003
Site Admin

Joined: Aug 28, 2003
Posts: 6799
Location: Ha Noi, Viet Nam
|
Posted:
Wed Feb 22, 2006 4:52 am |
|
So if you reload the text in the editor and highlight the word, click the formatting button you want to remove - it doesn't work?
Is that what you are saying?
For example, you highlight the word 'Testing' click B to make it bold, save it, then go back and open it again, highlight the word again and click the B again does not un-format it? |
|
|
|
 |
bfnuke

|
Posted:
Wed Feb 22, 2006 6:54 am |
|
Not quite. Really looking at the options where there is a pull down (style, format,font, size) there is no way to complete undo anything you select.
For example:
Highlight the word "Testing", go to the size pull down and select medium. save it, then go back and open it again, highlight the word again, click the size pulldown. There is no way to "remove" the <font> (you can select another one, but there is no way to completely remove the font tags).
You would use this when you want the CSS to have control over the text instead (at least that is what I am having a problem with) since the "local" <font> tags override the CSS... |
|
|
|
 |
Guardian2003

|
Posted:
Wed Feb 22, 2006 7:41 am |
|
Interesting.
I suppose the only quick workaround would be to switch to html mode and remove the tags manually but that kind of defeats the point of having a wysiwyg editor.
Hopefylly kguske can shed some more light on this. |
|
|
|
 |
bfnuke

|
Posted:
Wed Feb 22, 2006 8:40 am |
|
Yeah, that is what I have been doing, but like you said, it defeats the wysiwyg editor purpose.. |
|
|
|
 |
kguske
Site Admin

Joined: Jun 04, 2004
Posts: 6437
|
Posted:
Wed Feb 22, 2006 10:25 pm |
|
Sort of... Normally what happens is the HTML editor does insert the HTML for changing fonts, etc., but the theme (typically, the CSS) overrides it. Plus, if a user doesn't have the same theme on his or her PC, it will default to a different theme - defeating the purpose.
You can remove the ability to select fonts in the configuration for FCKeditor. The configuration contains the tool bars that basically define what tools are available for a give toolbar set. This affects security, so you have to be very careful about adding tools (which is why the Nuke user toolbar set is different from the Nuke admin toolbar set.
To change the toolbar configuration (or add your own toolsets), edit the includes/FCKeditor/fckconfig.js file. Look for the FCKConfig.ToolbarSets arrays. In case it's not obvious what to do, you can add or remove tools sets from these arrays to control what tools are available in the HTML editor. If you don't want users to have access to the fonts and size, for example, simply remove
Code: ['Style','FontFormat','FontName','FontSize'],
|
from the toolbar set. You can also remove specific tools (e.g. FontName). Just make sure you remove the appropriate brackets and commas, depending on what you want to change. |
_________________ I search, therefore I exist...
Only registered users can see links on this board! Get registered or login! |
|
|
 |
bfnuke

|
Posted:
Thu Feb 23, 2006 7:47 am |
|
But what I want is for the user to have the ability to remove the font, color, size html they already added via the editor. Removing the functionality is not really what I am looking for.
also you statement about the CSS overriding the html, it actually doesn't. It is the other way around (at least in my case). My default text is supposed to be a greenish color, but if I change it to "red" via the editor, then the color is read.. If the default size is 8px and I change it to Medium in the editor, it is definately not the same size... |
|
|
|
 |
kguske

|
Posted:
Thu Feb 23, 2006 10:26 pm |
|
Well, CSS will override - if it's defined. In some cases (like the ones you mentioned) the CSS isn't specified and won't override.
As for the font stuff, I'm a little confused (obviously!). You add the font stuff using the editor, but you want a magic button to remove it all?
If you paste stuff from Word, you will get a lot of extra stuff. That's why the Paste from Word button exists. There is a similar paste text button that strips out any formating before pasting. But that only works with pasting.
You can view the source and remove font tags, too, but there isn't a function to do this automatically. |
|
|
|
 |
bfnuke

|
Posted:
Fri Feb 24, 2006 6:40 am |
|
What I want is the ability to select the "font" called "default". IE. I write something up using the editor, change the font to maybe Arial. Save the item and then go look at it on the site. I don't like the way Arial made it look and like the way it looked with the "default" better. So I go back to the editor and try to remove the font from the item. Nope, no way to do that. so now I have to go and edit the source instead.
Can't really compare this to word because there is no concept of a "default" font in word.
right, there isn't a function to remove them automatically, but there is a function to add them. Just think the SHOULD be a function to remove anything the editor can add..
this also is relevant to size, color, etc as well.. |
|
|
|
 |
|