0

My site has an FB like button on a dynamic page. There are also mod re-write rules on the site to allow a friendly URL for that dynamic page.

i.e the following opages are the 'same':

(url 1) www.getawayearth.com/property.php?id=703

(url 2) www.getawayearth.com/property-rental/holidayhome703.html

The page has a like button on it. My problem is that the like button shows different values for each url, even though the the page is the 'same'. For example if you were to visit URL 1 an click on the like button, the like count would not be registered URL 2.

I understand why this is happening, however I was wondering if it is possible to set the like button to recognise the both urls as being the same?

Aldwoni
  • 1,168
  • 10
  • 24

2 Answers2

0

If you have multiple Like buttons which should all 'like' the same thing, you need to point the href of the like buttons to that URL - i.e on page 1 and page 2, both like buttons will be of the form <fb:like href="http://example.com/page1"/>

Igy
  • 43,710
  • 8
  • 89
  • 115
0

I understand your issue, and Open Graph meta tags could be a way to let Facebook now that 2 different URLs are the same by setting the same og::url meta on both each URL page.

The same issue occurs with SEO, and it's why there is a meta data named "canonical" to specify the official URL of a page, even if there is different URLs to reach the same page content.

<html>
<head>
      <meta name="title" content="your page title" />
      <link rel="canonical" href="http://your-official-page-URL" />

      <meta property="og:title" content="your page title" />
      <meta property="og:url" content="http://your-official-page-URL" />
</head>
…

Hope that can help.

Nassim
  • 31
  • 2