简体   繁体   中英

CKEditor stopped working after adding JSON to my MVC intranet

I have a intranet website where I have a page to add new products.

I use ckeditor because I need to save some links.

Now I had to change it into a Master detail form and so I decided to use Json2 and DataTables .

The strangest thing is that when I include

<script src="@Url.Content("~/Scripts/jquery-1.5.1.js")" type="text/javascript">

the ckeditor doesn't work anymore.

These are all the scripts I import

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

@*This is for CKEditor*@
<script src="@Url.Content("~/content/javascript/CKEditor/ckeditor.js")" type="text/javascript" ></script>
<script src="@Url.Content("~/content/javascript/CKEditor/adapters/jquery.js")" type="text/javascript" ></script>

@*This is for jquery*@
<script src="@Url.Content("~/Scripts/jquery-1.5.1.js")" type="text/javascript"></script>

@*This is for JSON*@
<script src="@Url.Content("~/Scripts/json2.js")" type="text/javascript"></script>

@*These are for DataTables*@
<script src="@Url.Content("~/Scripts/DataTables-1.9.4/media/js/jquery.dataTables.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/DataTables-1.9.4/extras/TableTools/media/js/TableTools.js")"
    type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/DataTables-1.9.4/extras/TableTools/media/js/ZeroClipboard.js")"
    type="text/javascript"></script>

@*These are for styling Control*@
<link href="@Url.Content("~/Content/DataTables-1.9.4/extras/TableTools/media/css/TableTools.css")"
    rel="stylesheet" type="text/css" />
<link href="@Url.Content("~/Content/DataTables-1.9.4/extras/TableTools/media/css/TableTools_JUI.css")"
    rel="stylesheet" type="text/css" />
<link href="@Url.Content("~/Content/themes/base/jquery.ui.all.css")" rel="stylesheet" type="text/css" />

Any ideas??

You should add the reference to jquery before you add ckeditor. The adaptors are set to extend jquery.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM