Source

facebook-python-sdk / examples / newsfeed / templates / base.html

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> 
    <title>{% block title %}Facebook Client Example{% endblock %}</title>
    <link rel="stylesheet" href="/static/base.css" type="text/css"/>
    {% block head %}{% endblock %}
  </head>
  <body>
    <div id="promo">This application is a demo of the <a href="http://developers.facebook.com/docs/api">Facebook Graph API</a>, the core part of the <a href="http://developers.facebook.com/">Facebook Platform</a>. <a href="http://github.com/facebook/python-sdk/blob/master/examples/client/facebookclient.py">See source code &raquo;</a></div>
    <div id="body">{% block body %}{% endblock %}</div>
    <div id="fb-root"></div>
    <script>
      window.fbAsyncInit = function() {
        FB.init({appId: '{{ facebook_app_id }}', status: true, cookie: true, xfbml: true});
        FB.Event.subscribe('auth.statusChange', function(response) {
          window.location.reload();
        });
      };
      (function() {
        var e = document.createElement('script');
        e.type = 'text/javascript';
        e.src = document.location.protocol + '//connect.facebook.net/en_US/all.js';
        e.async = true;
        document.getElementById('fb-root').appendChild(e);
      }());
    </script>
  </body>
</html>