當前位置:生活全書館 >

IT科技

> ueditor如何使用

ueditor如何使用

ueditor如何使用

第一步,找到對應遠程功能,查閱:ueditor.all.js檔案,發現如下代碼:

// plugins/catchremoteimage.js///import core///commands 遠程圖片抓取///commandsName  catchRemoteImage,catchremoteimageenable///commandsTitle  遠程圖片抓取/** * 遠程圖片抓取,當開啓本插件時所有不符合本地域名的圖片都將被抓取成爲本地服務器上的圖片 */UE.plugins['catchremoteimage'] = function () {    var me = this,        ajax = UE.ajax;    /* 設定默認值 */    if (me.options.catchRemoteImageEnable === false) return;    me.setOpt({        catchRemoteImageEnable: false    });    //.......};

有個配置參數:catchRemoteImageEnable

第二步,修改ueditor.config.js中的catchRemoteImageEnable配置參數

//抓取遠程圖片是否開啓,默認true,catchRemoteImageEnable:false

然後編輯器頁面,重新載入,然後複製粘貼遠程圖片,這時不再向服務端發送get請求catchimage。

標籤: ueditor
  • 文章版權屬於文章作者所有,轉載請註明 https://shqsg.com/zh-hant/dianzi/gry4v5.html