启用Chrome插件时,如何在我的网站上的图像中隐藏Pin It按钮

时间:2023-01-20 21:44:52

Hi I have chrome Pinterest plugin installed and when it is enabled, I see "Pin It" button (on hover) on all images on my website, How can i stop "Pin It" button to appear on my website, even when a chrome extension is enabled

嗨我安装了镀铬Pinterest插件,当它启用时,我在我的网站上的所有图像上看到“Pin It”按钮(悬停),如何停止“Pin It”按钮出现在我的网站上,即使是镀铬扩展已启用

After googling, I found the following on a blog:

谷歌搜索后,我在博客上发现了以下内容:

You can easily disable this as an individual who has installed the extension, but if you don’t want it to conflict with any other social software you may have on your site, all you need to do is add this to ever IMG tag:

您可以轻松禁用已安装扩展程序的个人,但如果您不希望它与您网站上可能拥有的任何其他社交软件冲突,您只需将其添加到IMG标记:

<img src="myimage.jpg" data-pin-no-hover />

启用Chrome插件时,如何在我的网站上的图像中隐藏Pin It按钮

But that's for single image, is there any other way to override the plugin to disable "pin it" button from chrome extension? using JS/jQuery?

但这是单个图像,有没有其他方法可以覆盖插件以禁用Chrome扩展程序中的“pin it”按钮?使用JS / jQuery?

Chrome extension js: http://assets.pinterest.com/ext/cr.js

Chrome扩展程序js:http://assets.pinterest.com/ext/cr.js

EDIT

<img src="myimage.jpg" data-pin-no-hover /> doesn't seem to work anymore

启用Chrome插件时,如何在我的网站上的图像中隐藏Pin It按钮似乎不再起作用了

7 个解决方案

#1


18  

Okay I just read the Pinterest documentation, To disable the pinterest on a page or website, just add a meta tag:

好的,我刚刚阅读了Pinterest文档,要禁用页面或网站上的pinterest,只需添加一个元标记:

<meta name="pinterest" content="nopin" />

And pinterest button will stop appearing on the website anymore.

并且pinterest按钮将不再出现在网站上。

#2


9  

Edit, sorry should say that my response addresses your edit specifically:

编辑,抱歉应该说我的回复专门针对您的编辑:

You need to specify the true switch for the attribute if you just want to disable the hover pin it button on one image.

如果您只想在一个图像上禁用悬停按钮,则需要为属性指定true开关。

<img src="myimage.jpg" data-pin-no-hover="true" />

... will do it

... 会做的

#3


3  

If you want to disable the hover pin it button on Google Chrome, use this mark up in your HEAD:

如果您要在Google Chrome上停用鼠标悬停按钮,请在HEAD中使用此标记:

<meta name="pinterest" content="nohover"></meta>

You can read more about it on Pinterest's blog: http://businessblog.pinterest.com/post/77184942682/a-smarter-pin-it-button

您可以在Pinterest的博客上阅读更多相关信息:http://businessblog.pinterest.com/post/77184942682/a-smarter-pin-it-button

using the no pin code disables pinning on that image

使用无引脚代码禁用该图像上的固定

Hope that helps,

希望有所帮助,

Kristie

#4


2  

I spent hours to figure this out, only to find that it is as easy as adding this to your image tag

我花了好几个小时来解决这个问题,但却发现它就像添加到图片代码一样简单

nopin="nopin"

#5


2  

You have two methods:

你有两种方法:

1) Disabling it to a single image (Charlie's answer), as you'd have done, but you have forgotten the value "true", it is necessary:

1)将它禁用为单个图像(查理的答案),就像你已经完成的那样,但是你忘记了值“真”,这是必要的:

<img src="myimage.jpg" data-pin-no-hover="true" />

2) Disabling it to the whole document (Saurabh Sharma's answer), at document's <head>:

2)在文档的中禁用整个文档(Saurabh Sharma的答案):

<meta name="pinterest" content="nopin" />

You just have to chose which case will suit you better.

您只需选择哪种情况更适合您。

#6


0  

If you want to disable it for all images, you could try the following jQuery:

如果要为所有图像禁用它,可以尝试以下jQuery:

$('img').attr('data-pin-no-hover', '');

#7


0  

Charlie's answer from Mar 12 '14 at 20:34 is now outdated. The most reliable method is to add nopin="nopin" as an image attribute:

查理在2014年3月12日20:34的回答现在已经过时了。最可靠的方法是添加nopin =“nopin”作为图像属性:

<img class="block__el--hide" src="path/imgname_1500x900.png" nopin="nopin">

启用Chrome插件时,如何在我的网站上的图像中隐藏Pin It按钮

~DR

#1


18  

Okay I just read the Pinterest documentation, To disable the pinterest on a page or website, just add a meta tag:

好的,我刚刚阅读了Pinterest文档,要禁用页面或网站上的pinterest,只需添加一个元标记:

<meta name="pinterest" content="nopin" />

And pinterest button will stop appearing on the website anymore.

并且pinterest按钮将不再出现在网站上。

#2


9  

Edit, sorry should say that my response addresses your edit specifically:

编辑,抱歉应该说我的回复专门针对您的编辑:

You need to specify the true switch for the attribute if you just want to disable the hover pin it button on one image.

如果您只想在一个图像上禁用悬停按钮,则需要为属性指定true开关。

<img src="myimage.jpg" data-pin-no-hover="true" />

... will do it

... 会做的

#3


3  

If you want to disable the hover pin it button on Google Chrome, use this mark up in your HEAD:

如果您要在Google Chrome上停用鼠标悬停按钮,请在HEAD中使用此标记:

<meta name="pinterest" content="nohover"></meta>

You can read more about it on Pinterest's blog: http://businessblog.pinterest.com/post/77184942682/a-smarter-pin-it-button

您可以在Pinterest的博客上阅读更多相关信息:http://businessblog.pinterest.com/post/77184942682/a-smarter-pin-it-button

using the no pin code disables pinning on that image

使用无引脚代码禁用该图像上的固定

Hope that helps,

希望有所帮助,

Kristie

#4


2  

I spent hours to figure this out, only to find that it is as easy as adding this to your image tag

我花了好几个小时来解决这个问题,但却发现它就像添加到图片代码一样简单

nopin="nopin"

#5


2  

You have two methods:

你有两种方法:

1) Disabling it to a single image (Charlie's answer), as you'd have done, but you have forgotten the value "true", it is necessary:

1)将它禁用为单个图像(查理的答案),就像你已经完成的那样,但是你忘记了值“真”,这是必要的:

<img src="myimage.jpg" data-pin-no-hover="true" />

2) Disabling it to the whole document (Saurabh Sharma's answer), at document's <head>:

2)在文档的中禁用整个文档(Saurabh Sharma的答案):

<meta name="pinterest" content="nopin" />

You just have to chose which case will suit you better.

您只需选择哪种情况更适合您。

#6


0  

If you want to disable it for all images, you could try the following jQuery:

如果要为所有图像禁用它,可以尝试以下jQuery:

$('img').attr('data-pin-no-hover', '');

#7


0  

Charlie's answer from Mar 12 '14 at 20:34 is now outdated. The most reliable method is to add nopin="nopin" as an image attribute:

查理在2014年3月12日20:34的回答现在已经过时了。最可靠的方法是添加nopin =“nopin”作为图像属性:

<img class="block__el--hide" src="path/imgname_1500x900.png" nopin="nopin">

启用Chrome插件时,如何在我的网站上的图像中隐藏Pin It按钮

~DR