<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ??一站式輕松地調用各大LLM模型接口,支持GPT4、智譜、豆包、星火、月之暗面及文生圖、文生視頻 廣告
                # 獲取 JSON 格式的內容 可以通過`editor.txt.getJSON`獲取 JSON 格式的編輯器的內容,`v3.0.14`開始支持,示例如下 ```html <div id="div1"> <p>歡迎使用 <b>wangEditor</b> 富文本編輯器</p> <img src="https://ss0.bdstatic.com/5aV1bjqh_Q23odCf/static/superman/img/logo_top_ca79a146.png" style="max-width:100%;"/> </div> <button id="btn1">getJSON</button> <script type="text/javascript" src="/wangEditor.js"></script> <script type="text/javascript"> var E = window.wangEditor var editor = new E('#div1') editor.create() document.getElementById('btn1').addEventListener('click', function () { var json = editor.txt.getJSON() // 獲取 JSON 格式的內容 var jsonStr = JSON.stringify(json) console.log(json) console.log(jsonStr) }) </script> ``` ----- 如果編輯器區域的 html 內容是如下: ```html <p>歡迎使用 <b>wangEditor</b> 富文本編輯器</p> <img src="https://ss0.bdstatic.com/5aV1bjqh_Q23odCf/static/superman/img/logo_top_ca79a146.png" style="max-width:100%;"/> ``` 那么獲取的 JSON 格式就如下: ```json [ { "tag": "p", "attrs": [], "children": [ "歡迎使用 ", { "tag": "b", "attrs": [], "children": [ "wangEditor" ] }, " 富文本編輯器" ] }, { "tag": "img", "attrs": [ { "name": "src", "value": "https://ss0.bdstatic.com/5aV1bjqh_Q23odCf/static/superman/img/logo_top_ca79a146.png" }, { "name": "style", "value": "max-width:100%;" } ], "children": [] }, { "tag": "p", "attrs": [], "children": [ { "tag": "br", "attrs": [], "children": [] } ] } ] ```
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看