1. <ul id="0c1fb"></ul>

      <noscript id="0c1fb"><video id="0c1fb"></video></noscript>
      <noscript id="0c1fb"><listing id="0c1fb"><thead id="0c1fb"></thead></listing></noscript>

      99热在线精品一区二区三区_国产伦精品一区二区三区女破破_亚洲一区二区三区无码_精品国产欧美日韩另类一区

      RELATEED CONSULTING
      相關(guān)咨詢
      選擇下列產(chǎn)品馬上在線溝通
      服務(wù)時(shí)間:8:30-17:00
      你可能遇到了下面的問題
      關(guān)閉右側(cè)工具欄

      新聞中心

      這里有您想知道的互聯(lián)網(wǎng)營銷解決方案
      HTML5如何實(shí)現(xiàn)微信聊天界面、微信朋友圈

      這篇文章主要介紹HTML5如何實(shí)現(xiàn)微信聊天界面、微信朋友圈,文中介紹的非常詳細(xì),具有一定的參考價(jià)值,感興趣的小伙伴們一定要看完!

      成都創(chuàng)新互聯(lián)專注為客戶提供全方位的互聯(lián)網(wǎng)綜合服務(wù),包含不限于成都網(wǎng)站建設(shè)、網(wǎng)站制作、鄠邑網(wǎng)絡(luò)推廣、小程序開發(fā)、鄠邑網(wǎng)絡(luò)營銷、鄠邑企業(yè)策劃、鄠邑品牌公關(guān)、搜索引擎seo、人物專訪、企業(yè)宣傳片、企業(yè)代運(yùn)營等,從售前售中售后,我們都將竭誠為您服務(wù),您的肯定,是我們最大的嘉獎(jiǎng);成都創(chuàng)新互聯(lián)為所有大學(xué)生創(chuàng)業(yè)者提供鄠邑建站搭建服務(wù),24小時(shí)服務(wù)熱線:13518219792,官方網(wǎng)址:www.cdcxhl.com

      html代碼片段:

      
      
          
          
              
              
                  
                  
                      為喜歡的節(jié)目打賞
                      
                          
                      
                                                            
                                                                    豪車霸屏50秒                         12                      
                                                   動(dòng)人玫瑰霸屏20秒                         8                      
                      
                  
              
                           支付 12 打賞         
          

      Javascript代碼片段:

      /* ——聊天編輯器區(qū)域 */
      var $editor = $(".J__editorText"), editor = $editor[0];
      var $face = $(".emotion-area dd img");
      $face.on("click", function(e){
          if($(this).hasClass("face")){ //圖像
              var img = $(this)[0].cloneNode(true);
              editor.focus();
              setTimeout(function(){
                  var range, node;
                  if(document.selection && document.selection.createRange){
                      document.selection.createRange().pasteHTML(img);
                  }else if(window.getSelection && window.getSelection().getRangeAt){
                      range = window.getSelection().getRangeAt(0);
                      range.insertNode(img);
                      range.collapse(false);
                      var sel = window.getSelection();
                      sel.removeAllRanges();
                      sel.addRange(range);
                  }
              }, 16);
          }else if($(this).hasClass("del")){ //刪除
              editor.focus();
              range = window.getSelection().getRangeAt(0);
              range.collapse(false);
              var sel = window.getSelection();
              sel.removeAllRanges();
              sel.addRange(range);
              document.execCommand("delete");
          }
      });
      //...格式化編輯器包含標(biāo)簽
      editor.addEventListener("focus", function(evt) {
          surrounds()
      }, true);
      editor.addEventListener("input", function(evt) {
          surrounds();
      }, false);
      function surrounds() {
          setTimeout(function () { //chrome
              var sel = window.getSelection();
              var anchorNode = sel.anchorNode;
              if (!anchorNode) return;
              if (sel.anchorNode === editor ||
                  (sel.anchorNode.nodeType === 3 && sel.anchorNode.parentNode === editor)) {
                  var range = sel.getRangeAt(0);
                  var p = document.createElement("p");
                  range.surroundContents(p);
                  range.selectNodeContents(p);
                  range.insertNode(document.createElement("br")); //chrome
                  sel.collapse(p, 0);
                  (function clearBr() {
                      var elems = [].slice.call(editor.children);
                      for (var i = 0, len = elems.length; i < len; i++) {
                          var el = elems[i];
                          if (el.tagName.toLowerCase() == "br") {
                              editor.removeChild(el);
                          }
                      }
                      elems.length = 0;
                  })();
              }
          }, 0);
      }
      //...滾動(dòng)到聊天內(nèi)容底部
      function scrollToBottom(){
          $('.ws__chatMsg-panel').animate({scrollTop: $("#J__chatMsgList").height()}, 300);
      }

      以上是“HTML5如何實(shí)現(xiàn)微信聊天界面、微信朋友圈”這篇文章的所有內(nèi)容,感謝各位的閱讀!希望分享的內(nèi)容對(duì)大家有幫助,更多相關(guān)知識(shí),歡迎關(guān)注創(chuàng)新互聯(lián)行業(yè)資訊頻道!


      網(wǎng)站題目:HTML5如何實(shí)現(xiàn)微信聊天界面、微信朋友圈
      瀏覽地址:http://www.ef60e0e.cn/article/jjopso.html

      其他資訊

      99热在线精品一区二区三区_国产伦精品一区二区三区女破破_亚洲一区二区三区无码_精品国产欧美日韩另类一区
      1. <ul id="0c1fb"></ul>

        <noscript id="0c1fb"><video id="0c1fb"></video></noscript>
        <noscript id="0c1fb"><listing id="0c1fb"><thead id="0c1fb"></thead></listing></noscript>

        张家港市| 邛崃市| 弋阳县| 文登市| 上高县| 云龙县| 海安县| 类乌齐县| 常德市| 泰顺县| 大兴区| 滦平县| 新泰市| 来凤县| 杂多县| 揭西县| 登封市| 鸡西市| 新竹市| 新乡市| 永顺县| 壤塘县| 梅河口市| 额尔古纳市| 柘荣县| 寻乌县| 明光市| 都昌县| 正宁县| 宁强县| 凌源市| 海安县| 九江县| 苗栗县| 日喀则市| 汝阳县| 桦川县| 云林县| 文水县| 玉龙| 若尔盖县|