0

我只是按照 froala 文档并使用 metronic 将其与当前布局混合。

这是我的 CSS 订单。

<link href="http://fonts.googleapis.com/css?family=Open+Sans:400,300,600,700&subset=all" rel="stylesheet" type="text/css"/>
<link href="assets/global/plugins/font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css"/>
<link href="assets/global/plugins/simple-line-icons/simple-line-icons.min.css" rel="stylesheet" type="text/css"/>
<link href="assets/global/plugins/bootstrap/css/bootstrap.min.css" rel="stylesheet" type="text/css"/>
<link href="assets/global/css/components-md.css" id="style_components" rel="stylesheet" type="text/css"/>
<link href="assets/global/css/plugins-md.css" rel="stylesheet" type="text/css"/>
<link href="assets/admin/layout2/css/layout.css" rel="stylesheet" type="text/css"/>
<link href="assets/admin/layout2/css/themes/grey.css" rel="stylesheet" type="text/css" id="style_color"/>
<link href="assets/admin/layout2/css/custom.css" rel="stylesheet" type="text/css"/>
<link rel="stylesheet" type="text/css" href="assets/coeg-editor/css/froala_editor.min.css" />
<link rel="stylesheet" type="text/css" href="assets/coeg-editor/css/froala_style.min.css" />

这是我的 JS 订单

<script src="assets/global/plugins/jquery.min.js" type="text/javascript"></script>
<script src="assets/global/plugins/jquery-migrate.min.js" type="text/javascript"></script>
<script src="assets/global/plugins/jquery-ui/jquery-ui.min.js" type="text/javascript"></script>
<script src="assets/global/plugins/bootstrap/js/bootstrap.min.js" type="text/javascript"></script>
<script src="assets/global/scripts/metronic.js" type="text/javascript"></script>
<script src="assets/admin/layout2/scripts/layout.js" type="text/javascript"></script>
<script type="text/javascript" src="assets/coeg-editor/js/froala_editor.min.js"></script>
<script>
$(function() {
   Metronic.init(); // init metronic core componets
   Layout.init(); // init layout
   $('a[href="{{ Request::url() }}"]').parent().addClass('active');
   $('textarea#content').editable({inlineMode: false});
});
</script>

我就Uncaught TypeError: undefined is not a function$('textarea#content').editable({inlineMode: false});

但是如果我评论$('textarea#content').editable({inlineMode: false});部分没有错误。

我该如何解决?

4

1 回答 1

1

有关使用 froalaEditor() 而不是 editable() 的信息,请参阅https://www.froala.com/wysiwyg-editor/v2.0/docs/migrate-from-v1

别介意包含仍然使用 v1 语法而不是 v2 的示例的 html:D

于 2015-10-04T09:30:42.860 回答