how to change color of facebook like button

后端 未结 9 1586
野的像风
野的像风 2020-12-07 01:36

using the guide at http://developers.facebook.com/docs/reference/plugins/like

I am trying to put a like button on my web page. How can i change the color of text [Be

9条回答
  •  广开言路
    2020-12-07 02:07

    Yes, it can be done. I will give you the first steps (just to REMOVE COLOR), then you can do a further research on -webkit-filter: hue-rotate to change the color, if you don't want just to remove it.

    First, add an #id to your FB code:

    You can leave your code as it is right now, just add that id="fboverlay" over there.

    Then edit your css and add:

    #fboverlay {
        opacity: 0.6;
        filter: alpha(opacity=60);
        -webkit-filter: grayscale(100%);
        -moz-filter: grayscale(100%);
        -o-filter: grayscale(100%);
        -ms-filter: grayscale(100%);
        filter: grayscale(100%);
    }
    

    Or whatever else you'd like. And that's it.

    Surely it's using CSS3, therefore it's not 100% compatible (specially with old browsers), but you know how it is...

提交回复
热议问题