• <menuitem id="y2t77"><video id="y2t77"><optgroup id="y2t77"></optgroup></video></menuitem>

    <code id="y2t77"></code>
    <ruby id="y2t77"><option id="y2t77"><optgroup id="y2t77"></optgroup></option></ruby>
      <tr id="y2t77"><small id="y2t77"></small></tr>
      <code id="y2t77"></code>

        圖片名

        咨詢熱線:0856-5202348 13885665889

        江口網站批量去除MySQL數據庫中文章內容的超鏈接

        分類:網絡安全 發布時間:2020-11-19 48435次瀏覽

        此方法是在保留文章內容的情況下去除超鏈接,適用于信息采集時入庫有別人的鏈接,自己...

        此方法是在保留文章內容的情況下去除超鏈接,適用于信息采集時入庫有別人的鏈接,自己寫著玩的,高手莫見笑 先刪除文章內容中超鏈接的前半部分: update articleset article_info.conten

        此方法是在保留文章內容的情況下去除超鏈接,適用于信息采集時入庫有別人的鏈接,自己寫著玩的,高手莫見笑


        先刪除文章內容中超鏈接的前半部分:


        update articleset article_info.content =

        replace(article.content,

        substring(article.content,

        locate('<a ', article.content),

        locate('>', article.content,locate('<a ', article.content))+1-locate('<a ', article.content)

        ),

        '');


        上部代碼執行一次能夠刪除文章內容中的第一個超鏈接,多執行幾次指導影響行數為0為止


        下面就是刪除文章內容中超鏈接的后半部分:


        update article_info set article_info.content =

        replace(article_info.content,'</a>','');


        另一個實用案例就是刪除DEDE文章中的鏈接且保留鏈接文字,用下邊的SQL語句:

        update dede_addonarticle set body = replace(body,substring(body,locate("<a ", body),locate(">", body,locate("<a ", body))+1-locate("<a ", body)),"");


        最近服務的一高校網站群系統,經常被主管部門掃描出違規信息鏈接,原因是歷史數據和站點太多,因一些部門網站存在很多外鏈網站,而這些外鏈網站有些沒有開辦了,然后域名被不法分子注冊,用于開設違規網站,在網絡安全要求越來越嚴格的今天,網站應該注意外鏈的審查,盡可能少開外鏈,鏈接也最好是一些大型的或gov.cn域名網站(比較穩妥)。

        亚洲无码。精品视频,欧美黄片a三级三级,免费无码理论电影在线播放,黄片在线看链接视频
      1. <menuitem id="y2t77"><video id="y2t77"><optgroup id="y2t77"></optgroup></video></menuitem>

        <code id="y2t77"></code>
        <ruby id="y2t77"><option id="y2t77"><optgroup id="y2t77"></optgroup></option></ruby>
          <tr id="y2t77"><small id="y2t77"></small></tr>
          <code id="y2t77"></code>