简体   繁体   English

我可以更改Facebook和Twitter分享按钮的样式吗

[英]Can I change the style of Facebook and Twitter share buttons

So when i'm using Twitter and Facebook share functionality I get the default share buttons that look like: 因此,当我使用Twitter和Facebook共享功能时,我会看到默认的共享按钮,如下所示: 脸书分享 Twitter分享

I read the policies and it states: Don't obscure or cover elements of social plugins. 我阅读了相关政策,其中指出: Don't obscure or cover elements of social plugins. Am I allowed to style the button? 我可以设置按钮的样式吗?

Instead of the default? 而不是默认值? Or is this against the Facebook/Twitters Policies? 还是这违反了Facebook / Twitters政策?

Facebook Do's and Don'ts : Facebook的注意事项

Don'ts 不要

  • Modify Facebook brand assets in any way, such as by changing the design or color 以任何方式修改Facebook品牌资产,例如通过更改设计或颜色

Twitter Usage Guidelines Twitter使用指南

Always use our official and unmodified Twitter logo to represent Twitter. 始终使用我们的官方且未经修改的Twitter徽标代表Twitter。

That said, Facebook and Twitter logos are highly modified on thousands of web pages across the web. 也就是说,Facebook和Twitter徽标已在网络上的数千个网页上进行了高度修改。 I think as long as you make your modifications elegant, professional and attractive, you won't face any enforcement action. 我认为,只要您对修改进行优雅,专业和有吸引力的修改,就不会面临任何强制措施。

If they do contact you, they'll likely start with a cease and desist notice. 如果他们确实与您联系,他们可能会先停止并停止通知。 At that point you can remove your modified logos and the enforcement measures normally stop. 此时,您可以删除修改后的徽标,并且通常会停止执行措施。

Just build your own in HTML and CSS. 只需使用HTML和CSS构建自己的代码即可。 It's really easy. 真的很简单。 Just make html links and design them with CSS. 只需进行html链接并使用CSS进行设计即可。 Put the Icon in it and ready. 将图标放入其中并准备就绪。 The URL for Sharing in Facebook is the following: 在Facebook中共享的网址如下:

http://www.facebook.com/sharer/sharer.php?u=[URL]

And for Twitter it is: 对于Twitter,它是:

https://twitter.com/intent/tweet?text=[TITLE]&url=[URL]&via=[USER]

All Things in brackets [] are Things you should fill in (manually or via PHP/JS). 方括号[]中的所有内容都是您应填写的内容(手动或通过PHP / JS)。 The URL should be clear. 网址应清晰。 The TITLE is the text for Twitter to Show with the tweet and the USER is the Name Twitter Shows in the tweet. TITLE是Twitter随推文显示的文本,而USER是Twitter在推文中显示的名称。 Like this »Some page title [URL] via @kaiserkiwi « 像这样»通过@kaiserkiwi的某些页面标题[URL]«

There are a couple of ways to achieve this. 有两种方法可以实现此目的。 The difficult way is to read lots of Twitter and Facebook documentation and use that to create something of your own. 困难的方法是阅读大量Twitter和Facebook文档,并使用它们来创建自己的东西。 The easy way is to use third party tools like AddThis. 简单的方法是使用第三方工具,例如AddThis。 You can easily customise buttons in any way you like. 您可以按自己喜欢的任何方式轻松自定义按钮。 If you're using WordPress, this is their plugin. 如果您使用的是WordPress,则是他们的插件。 You can also use ShareThis and their WordPress plugin . 您还可以使用ShareThis及其WordPress 插件 With ShareThis you can use their native CSS classes to overwrite default look and feel. 借助ShareThis,您可以使用其本机CSS类覆盖默认外观。 For example, after you install the plugin, choose custom option and then you can target the following classes: .st_twitter_custom and .st_facebook_custom. 例如,安装插件后,选择“定制”选项,然后可以定位以下类:.st_twitter_custom和.st_facebook_custom。 Hope, this helps. 希望这可以帮助。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM