0
Welcome Guest! Login
0 items Join Now

Using classes within TinyMCE

  • Using classes within TinyMCE

    Posted 17 years 11 months ago
    • Hey guys,

      I'm just playing around with those great "Rocket-Launcher" Packages. First of all, I want to say thanks alot for bundling some content with your templates.

      At the moment I just try to find out what's the best way to use more of those predefined CSS classes like "readon". I use TinyMCE for editing. When I select a text that has some "Read on" Button, TinyMCE tells me that the style that display such buttons is called "readon". Now when I try the same with new content, the style that I select (within TinyMCE) gets ignored.

      When I use plain HTML its included. So my question is: What that "styles"-dropdown within TinyMCE for when it doesn't save the selection. Am I doing something wrong?

      Thanks for your help!

      Oliver
  • Re: Using classes within TinyMCE

    Posted 17 years 11 months ago
    • I'm not sure what the styles in that editor are for. All I know for sure is that when you use that editor to place code, it strips it leaving you wonder why it isn't saving it. This is very common.

      To use the RT classes in the templates, it's best to turn off your editor and manually place the code.

      Mike
  • Re: Using classes within TinyMCE

    Posted 17 years 11 months ago
    • It is better to learn how to do all content manually, just pure code. It makes you understand better and allows you to "clean" out your codes :)
    • James Spencer / Developer & Support / Hull, UK
  • Re: Using classes within TinyMCE

    Posted 17 years 11 months ago
    • Yeah, I know. I do so in my own websites.

      But I'm just setting up a site for my mom. I toke joomla so she can manage it herself. I really can't tell her, that for a nice webdesign she has to use plain HTML code again.

      However, shouldn't it be possible to use Dreamweaver together with the stylesheet and paste the code into joomla?

      I think that might be a way to get her a nice workflow. Do you think this might work out?
  • Re: Using classes within TinyMCE

    Posted 17 years 11 months ago
    • phlux0r's Avatar
    • phlux0r
    • Sr. Rocketeer
    • Posts: 199
    • Thanks: 0

    Re: Using classes within TinyMCE

    Posted 17 years 10 months ago
    • Here's what I wrote as an answer in another thread but it may apply to your question...

      Both TinyMCE and JCE have mambot settings that allow you to either load the styles from template_css.css or a custom stylesheet. What I did recently was to create a custom.css stylesheet that is included in template_css.css with some custom content styles for my client. Then I set that custom.css in the editor "Custom CSS" mambot setting. That way only the styles from that stylesheet are shown in the editor style drop-down. If you use the custom.css approach and have the full styles in the file, then you will see what your applied style looks like right in the WYSIWYG editor.

      Care must be taken when applying the styles though. If the style is applied to a paragraph <p> then it's not going to work as it needs to be a <span> so the procedure could be:

      1. write your text as a paragraph
      2. apply your alert, info, etc.. style
      3. click inside the styled text and "unformat" the paragraph by setting the formatting dropdown to "--Format--" - this should revert the text to a span keeping the applied css style

      HTH
  • Re: Using classes within TinyMCE

    Posted 17 years 10 months ago
    • Thanks alot! That should do it!

      Gonna try it tonight :-)

Time to create page: 0.073 seconds