adding styles to TinyMCE

koffer - September 23, 2006 - 19:33

In tinymce i can put a list of some style for text, how can i modify and add styles to this menu?

fckstyles.xml

MySchizoBuddy - October 2, 2006 - 11:41

Look in fckstyles.xml
thats where u can add new styles and or edit old ones

tinymce profile

ufku - October 2, 2006 - 14:26

in tinymce settings for each profile you can define CSS classes for "styles" droplist. these classes must be in the Editor css file. so if you want additional classes you must add them to your css file.

--
Geneticists from METU

Add own button

MySchizoBuddy - October 3, 2006 - 01:25

Do you know how to add our own button. like a code button, which works just like the bold and italic ones.
Right now I have to apply it as a format from format select combo box.

create a plugin for tinymce

mortendk - October 3, 2006 - 22:43

what your trying to do is a plugin in tinymce.
RTFM-> http://tinymce.moxiecode.com/tinymce/docs/customization_plugins.html

a quick & dirty approach would be to make a javascript call to tinymce directly from the page
try something like

bold:  onclick="tinyMCE.execCommand('Bold');"
html stuff: onclick="tinyMCE.execCommand('mceInsertContent',false,'<b>Drüpal rocks</b>');"

hope it helps :)
/morten.dk *king of Denmark*

sweet, that is definetly

MySchizoBuddy - October 4, 2006 - 03:44

sweet, that is definetly easy
Do u know how to do that in fckeditor as well :) a quick shortcut way of adding a simple custom button

nopes

mortendk - October 4, 2006 - 06:09

have no idea bout the fck editor but theres a manual somewhere ;)

/morten.dk *king of Denmark*

 
 

Drupal is a registered trademark of Dries Buytaert.