友情链接加nofollow_如何在WordPress导航菜单中添加Nofollow链接

友情链接加nofollow

Many site owners prefer to add a nofollow tag to all external links. Adding a nofollow attribute to links in WordPress is extremely simple. However, it is not as clear for navigation menus. In this article, we will show you how to add nofollow links in WordPress navigation menus.

许多网站所有者倾向于将nofollow标记添加到所有外部链接。 WordPress中的链接添加nofollow属性非常简单。 但是,对于导航菜单尚不清楚。 在本文中,我们将向您展示如何在WordPress导航菜单中添加nofollow链接。

影片教学 (Video Tutorial)

演示地址

If you don’t like the video or need more instructions, then continue reading.

如果您不喜欢该视频或需要更多说明,请继续阅读。

First start by adding the external link to your WordPress navigation menu just like you would add any custom link.

首先,将外部链接添加到WordPress导航菜单中,就像添加任何自定义链接一样。

Simply visit Appearance » Menus and click on the link tab. Enter the URL and link text and then click on add to menu button.

只需访问外观»菜单 ,然后单击链接选项卡。 输入URL和链接文本,然后单击“添加到菜单”按钮。

Adding a custom link in WordPress menus

The external link you added will now appear in the Menu Structure column. You need to click on the downward arrow to expand the menu item. Like this:

您添加的外部链接现在将出现在“ 菜单结构”列中。 您需要单击向下箭头以展开菜单项。 像这样:

Expanding a menu item

Next, click on the Screen Options button at the top right corner of the screen and check the boxes next to Link Relationship (XFN) and Link Target options.

接下来,单击屏幕右上角的“ 屏幕选项”按钮,然后选中“ 链接关系”(XFN)和“ 链接目标”选项旁边的框。

Adding link relationship and target options to menu items

Now scroll back down to your expanded menu item, and you will notice two new options. Link Relationship and Open link in a new window/tab. You need to enter nofollow in the link relationship option. You can also check the open link in new window/tab option if you want.

现在向下滚动到展开的菜单项,您会注意到两个新选项。 链接关系和新窗口/选项卡中的打开链接。 您需要在链接关系选项中输入nofollow 。 如果需要,您还可以检查在新窗口/选项卡中的打开链接选项。

Adding nofollow to an outgoing link in navigation menus

Lastly, click on the Save Menu button to store your changes.

最后,单击“ 保存菜单”按钮以存储您的更改。

That’s all, you can now preview your site.

就是这样,您现在可以预览您的网站。

To make sure that a nofollow attribute is added to your link, you can take the mouse to the external link, right click and select inspect element. Your browser window will split into two. In the bottom window you will be able to see the HTML source for your link. It will display the nofollow attribute with your link.

为确保将nofollow属性添加到链接,可以将鼠标移至外部链接,右键单击并选择检查元素。 您的浏览器窗口将拆分为两个。 在底部窗口中,您将能够看到链接HTML源。 它将显示带有链接的nofollow属性。

An external link with nofollow attribute in WordPress navigation menu

We hope this article helped you learn how to add nofollow links in WordPress navigation menus. You may also like our tutorial on how to add image icons to navigation menus in WordPress.

我们希望本文能帮助您学习如何在WordPress导航菜单中添加nofollow链接。 您可能还喜欢我们的教程,该教程介绍了如何在WordPress的导航菜单添加图像图标

If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Google+.

如果您喜欢这篇文章,请订阅我们的YouTube频道 WordPress视频教程。 您也可以在TwitterGoogle+上找到我们。

翻译自: https://www.wpbeginner.com/wp-tutorials/how-to-add-nofollow-links-in-wordpress-navigation-menus/

友情链接加nofollow

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值