0
votes

I am having a weird problem with tinyMCE.

I have a .js file with this as content:

tinyMCE.init({
mode: "textareas",
theme: "advanced",
theme_advanced_toolbar_location: "top",
theme_advanced_buttons1: "italic,underline,separator,justifyleft,justifycenter,justifyright,separator,formatselect,separator,bullist,numlist,link,unlink",
theme_advanced_buttons2: "",
theme_advanced_buttons3: ""
})

when I comment all the lines out, tinyMCE editor posts back the value correctly to my HttpPost Edit() function (I'm using ASP.NET MVC3). The editor is the default editor with all the complete button and advanced theme. But what I want is a simple editor with few buttons, that's why I have all the settings as above. When they are as above , the tinymce editor looks as I specified (so my script link is correct from the .cshtml), but the problem is the content is not posted back to the HttpPost function so the value is unchanged.

Why is this? I checked the View Source fromthe browser for both versions and they are identical too.

FYI, based on searches, I have also added this:

$(document).ready(function () {

$("#mySubmitButton").click(function () {
    tinyMCE.triggerSave();
});
})

But obviously it has no effect so far.

Thanks in advance for your answer.

1

1 Answers

0
votes

Just a little thought. Can you make sure your js-file and your page are located int he same folder(?).