Mobile app version of vmapp.org
Login or Join
Heady270

: Facebook Like button for Retina Display I am using Facebook's Like button (https://developers.facebook.com/docs/reference/plugins/like/) but when displayed on Retina Display iPhone, the button looks

@Heady270

Posted in: #Facebook #Like

I am using Facebook's Like button (https://developers.facebook.com/docs/reference/plugins/like/) but when displayed on Retina Display iPhone, the button looks blurry as the Facebook logo is an image and it is scaled up for high DPI. Is there any way to render the like button for Retina Display?

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Heady270

1 Comments

Sorted by latest first Latest Oldest Best

 

@Gail5422790

You'll need to overwrite Facebook's CSS.

First, create a new FB icon that is twice as big as the original you wish to replace (when scaled down, it will look good on retina).

Next, overwrite this this...

.sp_like-send {
background-image: url(http://static.ak.fbcdn.net/rsrc.php/v2/yD/x/Q8FTZ0iJJF2.png);
background-repeat: no-repeat;
display: inline-block;
height: 14px;
width: 14px;
}


with...

.sp_like-send {
background-image: url(/images/new-fb-icon-you-made.png);
background-repeat: no-repeat;
display: inline-block;
height: 50%;
width: auto;
background-size: 100%;
}


Here are a few additional options -> coding.smashingmagazine.com/2012/08/20/towards-retina-web/

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme