lijietian 发表于 2013-8-9 15:20:03

关于kindeditor

我看到jeecg里面有集成kindeditor插件,但是没有ui控件来调用,于是我用kindeditor中的demo拷过来测试了一遍,提交的时候被valiform拦截了,保存不了



<%@ page language="java" import="java.util.*" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@include file="/context/mytags.jsp"%>
<!DOCTYPE html>
<html>
<head>
<title>影片管理</title>
<t:base type="jquery,easyui,tools,DatePicker,kindeditor"></t:base>
   <link rel="stylesheet" href="plug-in/kindeditor/themes/default/default.css" />
<link rel="stylesheet" href="plug-in/kindeditor/plugins/code/prettify.css" />
<script charset="utf-8" src="plug-in/kindeditor/kindeditor.js"></script>
<script charset="utf-8" src="plug-in/kindeditor/lang/zh_CN.js"></script>
<script charset="utf-8" src="plug-in/kindeditor/plugins/code/prettify.js"></script>
<script>
KindEditor.ready(function(K) {
   var editor1 = K.create('textarea', {
    cssPath : 'plug-in/kindeditor/plugins/code/prettify.css',
    uploadJson : 'plug-in/kindeditor/jsp/upload_json.jsp',
    fileManagerJson : 'plug-in/kindeditor/jsp/file_manager_json.jsp',
    allowFileManager : true,
    afterCreate : function() {
   var self = this;
   K.ctrl(document, 13, function() {
      self.sync();
      document.forms['formobj'].submit();
   });
   K.ctrl(self.edit.doc, 13, function() {
      self.sync();
      document.forms['formobj'].submit();
   });
    }
   });
   prettyPrint();
});
</script>
</head>
<body style="overflow-y: hidden" scroll="no">
<t:formvalid formid="formobj" dialog="true" usePlugin="password" layout="div" action="filmController.do?save">
<input id="id" name="id" type="hidden" value="${filmPage.id }">
<fieldset class="step">
   <div class="form">
      <label class="Validform_label">影片名字:</label>
      <input class="inputxt" id="name" name="name"
      value="${filmPage.name}" datatype="*">
      <span class="Validform_checktip"></span>
      </div>
   <div class="form">
      <label class="Validform_label">影片内容:</label>
      <%--<input class="inputxt" id="contant" name="contant" ignore="ignore"
      value="${filmPage.contant}">
      --%>
      <textarea name="contant" id="contant" ignore="ignore" cols="100" rows="8" style="width:500px;height:200px;visibility:hidden;">${filmPage.contant}</textarea>
      <span class="Validform_checktip"></span>
      </div>
   <div class="form">
      <label class="Validform_label">影片图片:</label>
      <input class="inputxt" id="picture" name="picture" ignore="ignore"
      value="${filmPage.picture}">
      <span class="Validform_checktip"></span>
      </div>
   <div class="form">
      <label class="Validform_label">影片作者:</label>
      <input class="inputxt" id="author" name="author"
      value="${filmPage.author}" datatype="*">
      <span class="Validform_checktip"></span>
      </div>
   </fieldset>
</t:formvalid>
</body>
页: [1]
查看完整版本: 关于kindeditor