Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Steven Wilber 103 posts 98 karma points
    Nov 27, 2009 @ 11:01
    Steven Wilber
    0

    TinyMCE v3 Templates and Umbraco 4.0.2.1

    Hi,

    I'm trying to re-instate the template button in TinyMCE for my client. They have pages such as these that they need to create:

    https://www.sbpct.nhs.uk/YourViews/ListeningtoYou/ListeningtoYou.aspx
    https://www.sbpct.nhs.uk/YourViews/CurrentPublicConsultations/DentalAccess.aspx

    On the page there are "design" elements, such as the bordered, round cornered boxes that they want to include.

    Design aside (this is a historical site that I'm trying to blend in with Umbraco, so there is no opportunity for a re-design at this stage) I felt that the best way to allow the client to include these round cornered elements into the page was to use the old "templates" button on TinyMCE. This is now missing in V4.

    I have found the following article and followed it very carefully:

    http://our.umbraco.org/wiki/how-tos/customizing-the-wysiwyg-rich-text-editor-%28tinymce%29/how-to-add-extra-html-functionality-to-tinymce

    However as soon as I add in the CustomConfig section at the bottom then the TinyMCE ceases to work. I've tried adjusting it to remove the apparent extraneous single quotes, but to no avail.

    Has anyone got this to work? What could I possibly be doing wrong?

    Any help gratefully appreciated.

     

    Cheers

    Steve

  • Steven Wilber 103 posts 98 karma points
    Nov 27, 2009 @ 11:41
    Steven Wilber
    1

    Well, before anyone put any time into this, it seems that:

    1. I pasted the wrong link for the info above. It should have been:
      http://our.umbraco.org/wiki/how-tos/enabling-the-%27template%27-plugin-for-tinymce
    2. The CustomConfig section is very delicate. I have found that placing it all on one line fixed the problem.
    3. If you use the Firefox plugin 'Web Developer', or even if you don't, but look in the Error Console you will see that there is an error for Unterminated String. Click on the link and it takes you right to the JS code generated by Umbraco for the TinyMCE editor. Once you see the code you should be able to work out where the problem is.

    Probably no one else has had any problems with this, but I'm posting this info for my future self who will forget and search all over again (hello future self - ask yourself now if you should have deliberately set off that alarm).

     

    Cheers

     

    Steve

     

  • Steven Wilber 103 posts 98 karma points
    Nov 27, 2009 @ 11:53
    Steven Wilber
    0

    Just for reference I've updated the Wiki with my findings.

    http://our.umbraco.org/wiki/how-tos/enabling-the-%27template%27-plugin-for-tinymce

  • Henrik Ladefoged 30 posts 100 karma points
    Nov 18, 2010 @ 14:02
    Henrik Ladefoged
    0

    Im really struggling with this. I now have it running without generating any jscript errors (putting it on one line) but the template button still won't appear. Anyone with experience on this matter? The link above to the wiki nolonger works it seems

    Using Umbraco 4.0.3 (Sadly can't upgrade to a more recent version at this time)

  • Steven Wilber 103 posts 98 karma points
    Dec 13, 2010 @ 15:21
    Steven Wilber
    0

    Hi Henrik,

     

    The link does work. Try again. If you don't have any luck, let me know and I'll send you through the contents.

    Cheers

    Steve

Please Sign in or register to post replies

Write your reply to:

Draft