This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import logging | |
| import facepy as facebook | |
| from django.conf import settings | |
| from django.contrib.auth.signals import user_logged_in | |
| from django.db import models | |
| from django.contrib.auth import logout | |
| from django.contrib.auth.models import User | |
| class FBAuthMiddleware(object): | |
| def __init__(self): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function refreshBackgrounds(selector) { | |
| // Chrome shim to fix http://groups.google.com/a/chromium.org/group/chromium-bugs/browse_thread/thread/1b6a86d6d4cb8b04/739e937fa945a921 | |
| // Remove this once Chrome fixes its bug. | |
| if (/chrome/.test(navigator.userAgent.toLowerCase())) { | |
| $(selector).each(function() { | |
| var $this = $(this); | |
| if ($this.css("background-image")) { | |
| var oldBackgroundImage = $this.css("background-image"); | |
| setTimeout(function() { | |
| $this.css("background-image", oldBackgroundImage); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <script> | |
| function invite() { | |
| var url = '/people/~/mailbox', | |
| body = { | |
| recipients: { | |
| values: [{ | |
| person: { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """ | |
| Get django-sekizai, django-compessor (and django-cms) playing nicely together | |
| re: https://github.com/ojii/django-sekizai/issues/4 | |
| using: https://github.com/jezdez/django_compressor.git | |
| and: https://github.com/ojii/django-sekizai.git@0.5 | |
| """ | |
| from compressor.templatetags.compress import CompressorNode | |
| from django.template.base import * | |
| def compress(data, name): |