Advertisement

There's no such thing as a stupid question, but they're the easiest to answer.
Login
Search

Advertisement

Web Design & Development Web Design & Development
Search Search
Search for:
Tech Support Guy > > >

Solved: Facebook Like Plugin Not Working


(!)

peterinwa's Avatar
peterinwa peterinwa is offline
Member with 108 posts.
THREAD STARTER
 
Join Date: May 2004
Experience: Beginner
30-Nov-2012, 11:57 PM #1
Solved: Facebook Like Plugin Not Working
First a question for someone that uses one!

I created a FB page basically to advertise my website. What I'm confused about is whether the URL in the plugin should be that of the FB page, or my website itself. And if it can be either, why would you chose one vs. the other?

Real FB novice here!

Second, I dropped the Like button code generated on FB into this simple webpage, and I get nothing displayed at all. Same in my actual website, but this will be simpler to look at. Any ideas?

Thanks so much,

Peter

I work in HTML and some JavaScript, but don't understand much of the below code:

Code:
<html>
<head>
<title>Blank Screen</title>
</head>
<body>
       
<div id="fb-root"></div>
<script>(function(d, s, id) {
  var js, fjs = d.getElementsByTagName(s)[0];
  if (d.getElementById(id)) return;
  js = d.createElement(s); js.id = id;
  js.src = "//connect.facebook.net/en_US/all.js#xfbml=1";
  fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>

<div class="fb-like" data-href="http://www.TherapyDogOrganizations.net" data-send="false" data-layout="box_count" data-width="55" data-show-faces="false" data-font="verdana"></div>

</body>
</html>
Ent's Avatar
Ent   (Josiah) Ent is offline Ent is a Trusted Advisor with special permissions.
Computer Specs
Trusted Advisor with 5,217 posts.
 
Join Date: Apr 2009
Location: United Kingdom
Experience: Intermediate
01-Dec-2012, 04:13 AM #2
Which do you want to promote more?
When someone pushes the like button, it adds a link to that page to their newsfeed/wall/profile/whatever facebook is calling it this week. If you think it's more useful to send people to the main site, the like button should point to the main site. Conversely if you care more about the facebook page, have the button point to the facebook page.

In theory you could add a like button for anything on your site, even a like button for google, but I'm not quite sure why you'd want to.
peterinwa's Avatar
peterinwa peterinwa is offline
Member with 108 posts.
THREAD STARTER
 
Join Date: May 2004
Experience: Beginner
01-Dec-2012, 12:41 PM #3
Quote:
Originally Posted by Ent View Post
Which do you want to promote more?
When someone pushes the like button, it adds a link to that page to their newsfeed/wall/profile/whatever facebook is calling it this week. If you think it's more useful to send people to the main site, the like button should point to the main site. Conversely if you care more about the facebook page, have the button point to the facebook page.

In theory you could add a like button for anything on your site, even a like button for google, but I'm not quite sure why you'd want to.
Thank you Josiah.

I had assumed that you could only Like a Facebook page, so I'd never thought about Liking my website and hadn't thought it out. I created my Facebook page to attract people on Facebook to my website. But there's no need to send people to my Facebook page if I can send them directly to my website, so I'll have the Like button Like my website.

Now I just have to figure out why the code isn't putting the Like button on my website.

Peter
Ent's Avatar
Ent   (Josiah) Ent is offline Ent is a Trusted Advisor with special permissions.
Computer Specs
Trusted Advisor with 5,217 posts.
 
Join Date: Apr 2009
Location: United Kingdom
Experience: Intermediate
01-Dec-2012, 05:33 PM #4
A few possibilities:
You're using an unsupported browser. Opera, for example, just doesn't work. It's annoying, but at least there aren't that many Opera users.
You have an error in the code. For example if you're trying to put the like button inside an illegal element (such as a span) it may not appear.
You have a privacy guard such as Ghostery for Firefox installed, which takes out facebook buttons.

Those are a few issues I've encountered, to see exactly what you'd be after would require looking at your code.
peterinwa's Avatar
peterinwa peterinwa is offline
Member with 108 posts.
THREAD STARTER
 
Join Date: May 2004
Experience: Beginner
01-Dec-2012, 07:57 PM #5
Thanks again, but I solved it. It simply wasn't displaying when I was looking at the code on my hard drive. When I moved it to the web, it appeared.

Thanks for your help.
As Seen On

BBC, Reader's Digest, PC Magazine, Today Show, Money Magazine
WELCOME TO TECH SUPPORT GUY!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.


(clock)
THIS THREAD HAS EXPIRED.
Are you having the same problem? We have volunteers ready to answer your question, but first you'll have to join for free. Need help getting started? Check out our Welcome Guide.

Search Tech Support Guy

Find the solution to your
computer problem!




Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools


WELCOME
You Are Using: Server ID
Trusted Website Back to the Top ↑