1 Star 0 Fork 296

天夜孤风/ueditor-plus

forked from ModStartLib/ueditor-plus 
Create your Gitee Account
Explore and code with more than 14 million developers,Free private repositories !:)
Sign up
文件
Clone or Download
submitFormDemo.html 1.77 KB
Copy Edit Raw Blame History
git authored 2025-04-15 13:37 +08:00 . 优化:清除缓存
<!DOCTYPE HTML>
<html>
<head>
<script src="./example.js"></script>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8"/>
<title></title>
<script type="text/javascript" charset="utf-8" src="../ueditor.config.js"></script>
<script type="text/javascript" charset="utf-8" src="editor_api.js"></script>
<style type="text/css">
body {
font-size: 14px;
}
</style>
<script>var _hmt = _hmt || [];
(function () {
var hm = document.createElement("script");
hm.src = "https://hm.baidu.com/hm.js?f84f35a44b5cc5c0b10c3fabdf0f322b";
var s = document.getElementsByTagName("script")[0];
s.parentNode.insertBefore(hm, s);
})();</script>
<link rel="stylesheet" href="./style.css"/>
</head>
<body class="demo-editor-page">
<div>
<h2>UEditorPlus提交示例</h2>
<form id="form" method="post" target="_blank">
<script type="text/plain" id="myEditor" name="myEditor">
<p>欢迎使用UEditorPlus</p>
</script>
<input type="submit" value="通过input的submit提交">
</form>
<p>
<button onclick="document.getElementById('form').submit()">通过js调用submit提交</button>
</p>
<script type="text/javascript">
var editor_a = UE.getEditor('myEditor', {initialFrameHeight: 500});
editor_a.addListener("contentchange", function () {
console.log('编辑器内容发生改变', editor_a.getContent());
})
//--自动切换提交地址----
var doc = document,
version = editor_a.options.serverUrl || editor_a.options.imageUrl || "php",
form = doc.getElementById("form");
form.action = "../_demo_server/handle.php?action=showPost";
</script>
</div>
</body>
</html>
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/wanggood/ueditor-plus.git
git@gitee.com:wanggood/ueditor-plus.git
wanggood
ueditor-plus
ueditor-plus
master

Search