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
# Example how to add rich editor capabilities to your models in admin. | |
from django.contrib.admin import site, ModelAdmin | |
import models | |
# we define our resources to add to admin pages | |
class CommonMedia: | |
js = ( | |
'https://ajax.googleapis.com/ajax/libs/dojo/1.6.0/dojo/dojo.xd.js', |
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
var ajax_links_selector = 'a.ajax'; | |
var content_selector = '#content'; | |
var first_call = true; | |
var navilevel_substring = 3; // how many chars from pathname are static (3 for languagecode like /de/) | |
/* needs jquery address loaded: http://www.asual.com/jquery/address/ | |
* | |
* needs feincms to be ajax-enabled: | |
* | |
* feincms/views/base.py: |
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
from django.db import models | |
from django.utils.text import ugettext_lazy as _ | |
from .contact_form_amended import ContactForm, ContactFormContent | |
class MultiContactFormContent(ContactFormContent): | |
FORM_CLASSES = {'simple-contact': ContactForm} | |
FORM_CHOICES = (('simple-contact', _('Simple contact form')),) |
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
# -*- coding: utf-8 -*- | |
""" | |
Extension for FeinCMS Page | |
""" | |
from django.conf import settings | |
from django.db import models | |
from django.contrib.sites.models import Site | |
from django.contrib.sites.managers import CurrentSiteManager | |
from django.utils.translation import ugettext_lazy as _ | |
from feincms.module.page.models import Page, PageManager |
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
""" | |
Support for embedding blogs as FeinCMS ApplicationContent | |
""" | |
from django import forms | |
from .models import Blog | |
from .views import blog_detail | |
def get_admin_fields(form, *args, **kwargs): |
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
var ajax_links_selector = 'a.ajax'; | |
var content_selector = '#content'; | |
var first_call = true; | |
var navilevel_substring = 3; // how many chars from pathname are static (3 for languagecode like /de/) | |
/* needs jquery address loaded: http://www.asual.com/jquery/address/ | |
* | |
* needs feincms to be ajax-enabled: | |
* | |
* feincms/views/base.py: |
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
TIME_ZONE = 'Asia/Riyadh' | |
LANGUAGE_CODE = 'ar' | |
ugettext = lambda s: s | |
LANGUAGES = ( | |
('ar', ugettext('Arabic')), | |
('en', ugettext('English')), | |
) |
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
# What's this? It's a monster list of Google domain names that have been found to refer | |
# users to sites that are monitored with Shaun Inman's "Mint" statistics package. http:/haveamint.com/ | |
# | |
# A huge number of these came from Shawn Blanc's domain list here: | |
# http://shawnblanc.net/2010/08/cleanup-mint-unique-referrers/ | |
# | |
# I merged them in to my existing list for this "MONSTAH LIST". Enjoy! | |
# | |
# To filter many, many of the Google search results from your "Newest Unique Referrers" results in | |
# Mint, copy the list below verbatim (don't include these "comment" lines) and paste them into your |