使用ueditor实现多图片上传案例——前台数据层(Index.jsp)
来源:互联网 发布:淘宝网的购买流程 编辑:程序博客网 时间:2024/05/18 14:22
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%><%String path = request.getContextPath();String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";%><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"><html><head> <title>完整demo</title> <meta http-equiv="Content-Type" content="text/html;charset=utf-8"/> <script type="text/javascript" src="jquery-1.8.3.js"></script> <script type="text/javascript" charset="utf-8" src="ueditor.config.js"></script> <script type="text/javascript" charset="utf-8" src="ueditor.all.min.js"> </script> <!--建议手动加在语言,避免在ie下有时因为加载语言失败导致编辑器加载失败--> <!--这里加载的语言文件会覆盖你在配置项目里添加的语言类型,比如你在配置项目里配置的是英文,这里加载的中文,那最后就是中文--> <script type="text/javascript" charset="utf-8" src="lang/zh-cn/zh-cn.js"></script> <style type="text/css"> div{ width:100%; } </style></head><body> <form action="UploadServlet" method="post" id="form_add"> <div> 商品名称:<input type="text" name="name" /> <input type="hidden" value="" id="picture" name="picture"/> </div><div> <h1>完整demo</h1> <script id="editor" type="text/plain" style="width:100%; margin:0px auto;height:300px;"></script></div> <input type="button" value="提交" id="btn_sub"/> </form><script type="text/javascript"> //实例化编辑器 //建议使用工厂方法getEditor创建和引用编辑器实例,如果在某个闭包下引用该编辑器,直接调用UE.getEditor('editor')就能拿到相关的实例 var ue = UE.getEditor('editor'); function getContent() { var content = UE.getEditor('editor').getContent(); var picture = document.getElementById("picture"); picture.value = content; } </script><script type="text/javascript">$(function(){$("#btn_sub").click(function(){getContent();$("#form_add").submit(); //提交});});</script></body></html>
阅读全文
0 0
- 使用ueditor实现多图片上传案例——前台数据层(Index.jsp)
- 使用ueditor实现多图片上传案例——Dao层(BaseDao)
- 使用ueditor实现多图片上传案例——Dao层(IBaseDaoUtil)
- 使用ueditor实现多图片上传案例——Dao层(IShoppingDao)
- 使用ueditor实现多图片上传案例——DaoImpl层(BaseDaoUtilImpl)
- 使用ueditor实现多图片上传案例——DaoImpl层(ShoppingDaoImpl)
- 使用ueditor实现多图片上传案例——Service层(IShoppingService)
- 使用ueditor实现多图片上传案例——ServiceImpl层(ShoppingServiceImpl)
- 使用ueditor实现多图片上传案例——截取字符串层Util(SubString_text)
- 使用ueditor实现多图片上传案例——Servlet层(UploadServlet)
- 使用Servlet上传多张图片——前台页面层(Index.jsp)
- 使用ueditor实现多图片上传案例
- 使用ueditor实现多图片上传案例——实体类(Shopping.java)
- java实现人脸识别源码【含测试效果图】——前台显示层(index.jsp)
- Ueditor JSP 图片上传
- ueditor的图片上传(jsp)
- ueditor 上传图片 无法获取到数据 jsp struts2+spring
- ueditor实现的图片上传(多图片上传的改造版本)
- 触碰大师们的思想(二)之 策略模式
- 使用ueditor实现多图片上传案例——截取字符串层Util(SubString_text)
- 使用ueditor实现多图片上传案例——Servlet层(UploadServlet)
- 项目banner设计网站
- Math 常用的方法
- 使用ueditor实现多图片上传案例——前台数据层(Index.jsp)
- volatile关键字
- 删除ubuntu,安装CentOS 7(原先是windows 8.1、ubuntu双系统)
- GoldenDream-十月
- TV颜色空间—YUV,YIQ,YCbCr
- 我的“游戏职业”生涯03
- Seetaface 01 Seetaface win10 vs2015编译(cmake自动配置,可选mfc界面)
- 洛谷 P1119 灾后重建(Floyd)
- 链队列