Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Right align Facebook like button

Tags:

I am able to put a Facebook like button on my website, but how do I make it to be right-aligned within the div/iframe it is in?

I tried applying various CSS properties, but I could not get anything to move in the iframe.

like image 743
Moshe Marciano Avatar asked Nov 07 '10 15:11

Moshe Marciano


2 Answers

I think this link could help too: http://shades-of-orange.com/post/2011/01/09/Embed-Facebook-Like-Button-e28093-Right-Align-with-css-and-Settings.aspx

It says to set the width to "0". Then the box will be autoresize by Facebook and you can apply a float right to that box.

like image 140
SequenceDigitale.com Avatar answered Oct 19 '22 23:10

SequenceDigitale.com


iframe is an inline element, you can use

text-align: right 

for a div that contains that iframe, or float the iframe to the right, but just make sure to clear the float afterwards.

sample: http://jsfiddle.net/Mujj6/3/
and: http://jsfiddle.net/Mujj6/5/

like image 27
nonopolarity Avatar answered Oct 20 '22 00:10

nonopolarity