Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>I'm pretty new to MVC (a little over a year) and was pretty interested in spell check for a specific page in my solution. The above options may work for some folks, but didn't work for me (I'm not very patient, and in all honesty didn't want to ignore any routes, or modify my the system.web section of my config for something that only 5% of my solution consumers are going to use, so I didn't spend a whole lot of time on those options).</p> <p>So:</p> <ol> <li>I copied the Moxiecode.TinyMCE.dll file to a directory in my project so future contributors will have the dll without having to search google.</li> <li>I added a reference to the above dll to my project.</li> <li><p>I created a new controller called SpellCheckController.cs that contains the following:</p> <pre><code>public void CheckSpelling() { SpellCheckerModule spellChecker = new SpellCheckerModule(); spellChecker.ProcessRequest(System.Web.HttpContext.Current); } </code></pre></li> </ol> <p>(don't forget the using Moxiecode.TinyMCE.SpellChecker;)</p> <p>and just referenced the controller like this in the setup options for TinyMCE in my view:</p> <pre><code>spellchecker_rpc_url: "@Url.Action("CheckSpelling","SpellCheck")/?module=SpellChecker" </code></pre> <p>I haven't ignored any routes. I haven't added another httphandler to the what I am assuming is a pretty long list of handlers for .net, and spell check works for me now. </p> <p>I also have the ability to go with something different without changing too much (assuming I figure out what TinyMCE's spellchecker is doing with the http context.</p> <p>P.S. Stack Overflow's rich text editor doesn't seem to have a spell check feature, so there are no guaranties on the above spelling :)</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload