Sign up Sign in Samples Blog contact support
wysiwyg

WYSYWIG = What You See Is What You Get

Wagn uses the customizable TinyMCE editor for user-friendly editing of rich text, so that users don't have to learn a lot of markup.

 
+example

Our *tinyMCE card here on wagn.org has:

theme_advanced_buttons1 : "formatselect,bold,italic,"

The "formatselect" is what makes the menu appear in our edit toolbar, and the "bold" and "italic" puts the corresponding buttons there as well:

79041 original

There's also a line with:

theme_advanced_blockformats : "p,h1,h2,pre",

...which is why the menu offers Paragraph, Heading 1, Heading 2, and Preformatted.

 
+howto

Simply edit the *tinyMCE card to your heart's content (on your Wagn — here, you can only edit it if you have the role of Developers). See the TinyMCE configuration documentation and especially their button documentation to learn about everything that you can do.

 

+tips
  • You can separate very long lines contained in quotes by putting an endquote and starting a new line with a plus and opening the quote again. We use this trick in our *tinyMCE card to keep theme_advanced_buttons1 and extended_valid_elements from running off the right edge of the card:
    *tinyMCE
    { "width":"100%", "auto_resize":true, "relative_urls":false, "theme":"advanced", "theme_advanced_buttons1":"formatselect,bold,italic,separator,blockquote,bullist,numlist,hr,separator,code,removeformat", "theme_advanced_buttons2":"", "theme_advanced_buttons3":"", "theme_advanced_path":false, "theme_advanced_toolbar_location":"top", "theme_advanced_toolbar_align":"left", "theme_advanced_resizing":true, "theme_advanced_resize_horizontal":false, "theme_advanced_statusbar_location":"bottom", "theme_advanced_blockformats":"p,h1,h2,pre", "extended_valid_elements":"a[name|href|target|title|onclick],img[class|src|border=0|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name],hr[class|width|size|noshade],font[face|size|color|style],span[class|align|style]" }
  • To format text as monospaced (as you see in the example above), you can add "pre" to theme_advanced_blockformats and "Preformatted" will appear as an option in the Format menu.