Facebook JS affect CSS / @ font-face in IE?

It seems to me that Facebook JS

<div id="fb-root"></div> <script src="http://connect.facebook.net/en_US/all.js#appId=APP_ID&amp;xfbml=1"></script> 

seems to affect my CSS site in IE. eg. for example, headers use font1 and body use font2. sometimes in IE all fonts use font1 or even swap, headers use font2 and body use font1 ... It also seems to affect some PIE CSS , Anyone who has the same problem?

+2
source share
1 answer

I had the same problem. I use the downloaded font for my headers and on IE8, Facebook Javascript messed up the fonts. This happened when I structured my code in what I assumed was proper architecture - the inclusion of Javascript on Facebook was in my header, including the rest of my Javascript.

When I moved javascript turned on before the actual div that added a similar button, the problem disappeared.

  <div id="facebooklike" style="position: absolute; left: 645px; top: -37px;"> <div id="fb-root"></div><script src="http://connect.facebook.net/en_US/all.js#xfbml=1"></script><fb:like href="http://www.tripinsurance.com" send="false" width="350" show_faces="false" font="arial"></fb:like> </div> 

I think a problem can occur if the Facebook code is loaded before the div is loaded on the page.

+2
source

All Articles