asp.net mvc - CKEditor - move skins folder somewhere else -


i'm using ckeditor first time , trying thought simple far i've had no success.

essentially want place editor.js, config.js , styles.js in scripts folder want "skins" folder contains css , images appear within separate "styles" folder.

the application consists of simple view displays editor on load.

the code display editor follows:

angular.element(document).ready(function () {     ckeditor.config.contentscss = '/styles/ckeditor/';     ckeditor.replace('editor'); }); 

the html within view follows:

@section scripts {     <script src="~/scripts/ckeditor.js" type="text/javascript"></script>     <script src="~/scripts/angular.js"></script>     <script src="~/scripts/main.js" type="text/javascript"></script> }  <h2>index</h2>  <textarea id="editor" name="editor"></textarea> 

this mvc application , scripts rendered @ end of body within layout view.

the editor not display in browser. understand setting contentscss property should trick.

if place skins beneath script folder works fine. can see in generated source adding link header pointing /scripts/skins/moono..., want add reference /styles/skins/moono...

is trying feasable , if missing here? expecting simple.

as work around add routing rules redirects relevant request different location, i'd rather bottom of issue before this.

further information:

  • my application asp.net 4.5/mvc 4 app.
  • i'm referencing angular because i'll using once i've sorted issue. have tried removing references angular problem still persists.
  • i've tried setting contentscss property in following ways:
    • directly using ckeditor.config.contentscss
    • within config.js file. sample assigns anonymous function ckeditor.editorconfig , in there can manipulate congif entries.
    • passing config parameter when calling "replace" method on ckeditor object.
    • i've tried manipulating contentscss property both before , after call replace.
  • i'm using latest version of ckeditor (4.2)

thanks @richard deeming, i've found answer.

i'm using default moono style, needed set ckeditor.config.skin property follows:

ckeditor.config.skin = 'moono,/styles/ckeditor/skins/moono/' 

my final code looks this:

angular.element(document).ready(function () {     ckeditor.config.skin = 'moono,/styles/ckeditor/skins/moono/';     ckeditor.replace('editor'); }); 

you have set url actual folder containing skin (i thought ckeditor might append skins/mooono doesn't).

i found must include final '/' url.


Comments

Popular posts from this blog

php - get table cell data from and place a copy in another table -

javascript - Mootools wait with Fx.Morph start -

php - Navigate throught databse rows -