脚本包含的URL错误的Ckeditor文件 [英] Ckeditor files included by script with wrong url
本文介绍了脚本包含的URL错误的Ckeditor文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个简单的页面...并且我使用ckeditor可以在localhost上正常工作,但是我发布了确保它不再工作的公告...这是网站 http://testckedit.azurewebsites.net/代码:
I have a simple page...and i use ckeditor it works just fine o the localhost but wen i publish to azure it dose-nt work anymore... here is the site http://testckedit.azurewebsites.net/ the code:
bundles.Add(new ScriptBundle("~/bundles/bootstrap").Include(
"~/Scripts/bootstrap.js",
"~/Scripts/respond.js",
"~/Scripts/ckeditor/ckeditor.js"
));
和视图:
@{
ViewBag.Title = "Index";
}
<h2>Index</h2>
<div class='description'>
<p>
This editor is using an <code><iframe></code> element-based editing area, provided by the <strong>Wysiwygarea</strong> plugin.
</p>
</div>
<textarea cols="80" id="editor1" name="editor1" rows="10"></textarea>
@section scripts{
<script>
$(document).ready(function () {
// This call can be placed at any point after the
// <textarea>, or inside a <head><script> in a
// window.onload event handler.
// Replace the <textarea id="editor"> with an CKEditor
// instance, using default configurations.
CKEDITOR.replace("editor1");
});
</script>}
<p>
<input type="submit" value="Submit">
</p>
我在控制台上遇到了一些错误:
i got a few error at console:
Failed to load resource: the server responded with a status of 404 (Not Found) /config.js?t=DBAA
Failed to load resource: the server responded with a status of 404 (Not Found) /skins/moono/editor.css?t=DBAA
Failed to load resource: the server responded with a status of 404 (Not Found) /lang/ro.js?t=DBAA
Uncaught TypeError: Cannot set property 'dir' of undefined
推荐答案
我认为设置 CKEDITOR.basePath
应该可以解决这个问题.
I think that setting CKEDITOR.basePath
should do the trick for you.
这篇关于脚本包含的URL错误的Ckeditor文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文