Mind blowing SEO improving and Google rank increasing Signature Rotator SEO Tool.

Load Facebook like button on mouseover

make money online
ivan Offline referral

Posts: 717
Joined: Jul 2013
Reputation: 6

Senior Member
Hi I have just noticed letsforum.com added this Facebook like button that loads on mouseover. How can I add something similar to my website, of-course if you don't mind to tell me that.
marcus_avrelius Offline referral

Posts: 2,507
Joined: May 2013
Reputation: 109

Support Team
No problem! To add Facebook like button like I have added do this:

Add this code to where you want your like button to show
<div id="fblikediv"><img src="images/fb-like-button.png" id="fblikeimg" onMouseOver="return renderFbLike();"></div>

Make sure to point to you like image! Mine is in "images/fb-like-button.png"

Now add this JavaScript code, ideally after <body> tag
<script type="text/javascript">
    function renderFbLike() {
        var parent = document.getElementById('fblikediv');
        var child = document.getElementById('fblikeimg');
        var html2 = "Add your Facebook like button iFrame code here";
            document.getElementById('fblikediv').innerHTML = html2;

Replace "Add your Facebook like button iFrame code here" with your iFrame code

This is it very easy and helps to increase your site's load time 001_thumbup
chod Offline referral

Posts: 860
Joined: Jul 2013
Reputation: 85

Posting Freak
I get that adding in the iframe, may increase load time, but it should not be set in stone by any means. And you really should not see any difference in your site load speeds.

Where you trying to say decrease the load time? Cause increasing is bad Tongue

But regardless I do not see how adding the iframe will decrease your load time, actually I would bet a bunch of money it has nothing to do with the iframe from FB
maya Offline referral

Posts: 1,057
Joined: May 2013
Reputation: 34

Posting Freak
Chod with iFrame or without you will still lose somewhere between 0.5 and 1 second in load time. The more social media buttons you add the longer your site will load!
marcus_avrelius Offline referral

Posts: 2,507
Joined: May 2013
Reputation: 109

Support Team
If you are wondering how can I make Facebook like buttons faster then refer to this link!

You have to use Asynchronous JavaScript that doesn't interfere with your site code it load on the background thus decreasing site load time!
Ametuniversity Offline referral

Posts: 408
Joined: Feb 2019
Reputation: 0

Senior Member
Hide the facebook like iframe initially: .facebook-like{ display:none; }

Google this topic

User(s) browsing this thread: 1 Guest(s)