J
J
Jony13372017-03-20 18:19:06
Facebook
Jony1337, 2017-03-20 18:19:06

Why is opengraph facebook not working properly?

There is such html code, everything is strictly according to the textbook from their site

<!DOCTYPE html>
<html lang="en-US">
<head>
<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Roboto%3A300%2C400%2C700%2C900%7CMontserrat+Alternates%3A400%2C700" /> 
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<meta name="description" content="Jared Padalecki-Most Handsome Hollywood Actors 2017 Poll"/>
<meta property="og:type" content="website" />
<meta property="og:title" content="Jared Padalecki-Most Handsome Hollywood Actors 2017 Poll"/>
<meta property="og:description" content="Jared Padalecki-Most Handsome Hollywood Actors 2017 Poll"/>
<meta property="og:image" content="https://c3.staticflickr.com/2/1441/25211124146_89490c0e93_o.jpg?rand=77012451"/>
<meta property="og:image:url" content="https://c3.staticflickr.com/2/1441/25211124146_89490c0e93_o.jpg?rand=56160325"/>
<meta property="og:image:width" content="380"/>
<meta property="og:image:height" content="790"/>
<meta property="og:url" content="http://gnr-enterprise.ru/vote-fb/vote-view3.php?id=2&participant=1&rand=17195359"/>
<title>Jared Padalecki-Most Handsome Hollywood Actors 2017 Poll</title>

here is the button code
<!-- Load Facebook SDK for JavaScript -->
<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/ro_RO/sdk.js#xfbml=1&version=v2.7";
  fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));
</script>
<script>
function openWin(){
var win = window.open("https://www.facebook.com/sharer/sharer.php?u=http://gnr-enterprise.ru/vote-fb/vote-view3.php?id=2&participant=1&rand=54188007", "Facebook", "width=1300 height=700");

var pollTimer = window.setInterval(function() {
    if (win.closed !== false) {
    window.clearInterval(pollTimer);
        someFunctionToCallWhenPopUpCloses();
  }
}, 200);

function someFunctionToCallWhenPopUpCloses() {
    window.setTimeout(function() {
        if (win.closed) {
      alert('share goods');			
        }
    }, 1);
}}
</script>

When sharing, the photo does not show, the text does not show, well, here is the screen prntscr.com/elxnqt

Answer the question

In order to leave comments, you need to log in

1 answer(s)
P
Philipp, 2017-03-20
@zoonman

And it shouldn't, because your address doesn't match the canonical one.
I recommend looking here
https://developers.facebook.com/tools/debug/sharin...
By the way, I recommend looking at the source of the view-source page: gnr-enterprise.ru/vote-fb/vote-view3.php?id= 2&part...
It returns invalid HTML code.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question