<code id='ADFDB67927'></code><style id='ADFDB67927'></style>
    • <acronym id='ADFDB67927'></acronym>
      <center id='ADFDB67927'><center id='ADFDB67927'><tfoot id='ADFDB67927'></tfoot></center><abbr id='ADFDB67927'><dir id='ADFDB67927'><tfoot id='ADFDB67927'></tfoot><noframes id='ADFDB67927'>

    • <optgroup id='ADFDB67927'><strike id='ADFDB67927'><sup id='ADFDB67927'></sup></strike><code id='ADFDB67927'></code></optgroup>
        1. <b id='ADFDB67927'><label id='ADFDB67927'><select id='ADFDB67927'><dt id='ADFDB67927'><span id='ADFDB67927'></span></dt></select></label></b><u id='ADFDB67927'></u>
          <i id='ADFDB67927'><strike id='ADFDB67927'><tt id='ADFDB67927'><pre id='ADFDB67927'></pre></tt></strike></i>

          WordPre一分赛车投注网站ss无征途国际app官方下载插件外部链接自动添加nofollow标签

          2025-06-19 20:02:52 32376
          有些外部链接是没有加Nofollow标签,在技术层面是有传递出去权重。当然我们也可以通过代码实现无插件添加方法。

          在wordpress写文章时,当然目前一些wordpress主一分赛车投注网站题设置有这个nofollow标签功能。征途国际app官方下载

          //文章自动nofollowadd_filter( 'the_content', 'tin_seo_wl');function tin_seo_wl( $content ) {    $regexp = "<a\s[^>]*href=(\"??)([^\" >]*?)\\1[^>]*>";    if(preg_match_all("/$regexp/siU", $content, $matches, PREG_SET_ORDER)) {        if( !empty($matches) ) {               $srcUrl = get_option('siteurl');            for ($i=0; $i < count($matches); $i++)            {                   $tag = $matches[$i][0];                $tag2 = $matches[$i][0];                $url = $matches[$i][0];                   $noFollow = '';                $pattern = '/target\s*=\s*"\s*_blank\s*"/';                preg_match($pattern, $tag2, $match, PREG_OFFSET_CAPTURE);                if( count($match) < 1 )                    $noFollow .= ' target="_blank" ';                   $pattern = '/rel\s*=\s*"\s*[n|d]ofollow\s*"/';                preg_match($pattern, $tag2, $match, PREG_OFFSET_CAPTURE);                if( count($match) < 1 ) $noFollow .= ' rel="nofollow" '; $pos = strpos($url,$srcUrl); if ($pos === false) { $tag = rtrim ($tag,'>');                    $tag .= $noFollow.'>';                    $content = str_replace($tag2,$tag,$content);                }            }        }    }       $content = str_replace(']]>', ']]>', $content);    return $content;}

          添加到当前主题Funcions.php 文件中,如果手动每个链接加入是很麻烦,这样所有的外部链接就会自动加上nofollow标签。严格要求的话一分赛车投注网站trong>征途国际app官方下载是需要在外部链接全部加上nofollow标签。

          有时内容会引用或分享一些外部链接地址,可以直接找一些wordpress插件安装。
          本文地址:http://pni1y.xny028cc.com/raise/6.html
          版权声明

          本文仅代表作者观点,不代表本站立场。
          本文系作者授权发表,未经许可,不得转载。

          热门标签

          全站热门

          高温+越障,追觅S50Pro水箱版仅需2673元,智能洗地新标杆

          个人域名IPC备案/网站备案注意事项

          AI加持电竞模式!iQOO新款智能手表799元起,运动健康好帮手

          浏览器网页上的图片如何批量保存下载?

          11.6亿元!沂源县沂河沂源源头水保护区环境治理与产业开发EOD项目一期将招标

          web前端CSS传统布局position属性

          wordpress个人网站如何搬到电脑本地修改

          WordPress文章历史修订版本与自动草稿保存问题

          友情链接