2020年9月18日 星期五

[研究][ASP.NET][WebForm] RichTextEditor 8.0.1 WYSIWYG HTML Editor 試用 (付費)

[研究][ASP.NET][WebForm] RichTextEditor 8.0.1 WYSIWYG HTML Editor 試用 (付費)

2020-09-17

WYSIWYG HTML Editor = 所見即所得 HTML 網頁編輯器

WYSIWYG = What You See Is What You Get 

官方網站
https://richtexteditor.com/

定價
https://richtexteditor.com/pricing.aspx

社群版:會有 "Powered by" 文字
What are the limitations of the community version?
All features work the same as they do in the full version. The community version allows you run editor on one domain and it has "Powered by" text in the footer.

Rich Text Editor 範例
https://richtexteditor.com/demos/default.aspx















NuGet 版沒 License 不能用。

********************************************************************************
偶然發現官方網站版本 1.012 和 NuGet 版本 8.2.0.9 差異很大,可能大改版重新給版號。下載用看看

官方網站






********************************************************************************
自己寫個程式試試


Default.aspx
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="RTETest.Default" %>
<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title></title>
    <link rel="stylesheet" href="/richtexteditor/rte_theme_default.css" />
	<script type="text/javascript" src="/richtexteditor/rte.js"></script>
	<script type="text/javascript" src='/richtexteditor/plugins/all_plugins.js'></script>
</head>
<body>
    <form id="form1" runat="server">
        <input name="htmlcode" id="inp_htmlcode" type="hidden" />
        <div id="div_editor1" class="richtexteditor" style="width: 960px; margin: 0 auto;"></div>       
        <script>
            var editor1 = new RichTextEditor(document.getElementById("div_editor1"));
            editor1.attachEvent("change", function () {
                document.getElementById("inp_htmlcode").value = editor1.getHTMLCode();
            });
        </script>
    </form>
</body>
</html>


Default.aspx 這樣寫也可以
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="RTETest.Default" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title></title>
    <link rel="stylesheet" href="/richtexteditor/rte_theme_default.css" />
	<script type="text/javascript" src="/richtexteditor/rte.js"></script>
	<script type="text/javascript" src='/richtexteditor/plugins/all_plugins.js'></script>
</head>
<body>
    <form id="form1" runat="server">
        <div id="div_editor1" class="richtexteditor" style="width: 960px; margin: 0 auto;"></div>--%>
        <asp:TextBox ID="TextBox1" runat="server" TextMode="MultiLine" Rows="5" Columns="80"></asp:TextBox>
        <script>
            var editor1 = new RichTextEditor('TextBox1');
        </script>
    </form>
</body>
</html>


(下圖) 執行結果


(下圖) 定價

https://richtexteditor.com/pricing.aspx


(完)

沒有留言:

張貼留言