Skip to content
This repository has been archived by the owner on Mar 19, 2020. It is now read-only.

Commit

Permalink
Merge branch 'hotfix/bug811672-google-analytics'
Browse files Browse the repository at this point in the history
  • Loading branch information
peterbe committed Nov 28, 2012
2 parents 76f340e + f9e05d2 commit 4eaf261
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 70 deletions.
6 changes: 3 additions & 3 deletions apps/homepage/context_processors.py
Expand Up @@ -3,12 +3,12 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/.

"""
Make the settings `INCLUDE_WEBTRENDS` available to all templates so it can
Make the settings `INCLUDE_ANALYTICS` available to all templates so it can
be used in the base.html template.
"""
from django.conf import settings



def webtrends(request):
return {'include_webtrends': settings.INCLUDE_WEBTRENDS}
def analytics(request):
return {'include_analytics': settings.INCLUDE_ANALYTICS}
6 changes: 3 additions & 3 deletions settings/base.py
Expand Up @@ -62,7 +62,7 @@
TEMPLATE_CONTEXT_PROCESSORS += (
'django.core.context_processors.static',
'accounts.context_processors.accounts',
'homepage.context_processors.webtrends',
'homepage.context_processors.analytics',
)

# This is the common prefix displayed in front of ALL static files
Expand Down Expand Up @@ -179,8 +179,8 @@
L10N_FEED_URL = 'http://planet.mozilla.org/l10n/atom.xml'
HOMEPAGE_FEED_SIZE = 5

## WebTrends
INCLUDE_WEBTRENDS = False
## Google Analytics
INCLUDE_ANALYTICS = False


try:
Expand Down
4 changes: 2 additions & 2 deletions settings/local.py-dist
Expand Up @@ -53,8 +53,8 @@ SESSION_COOKIE_SECURE = False
# Feed for example, to avoid having to do a HTTP call for the feed use:
#L10N_FEED_URL = 'file://' + os.path.abspath('apps/homepage/test_rss20.xml')

# Enable WebTrends in production
#INCLUDE_WEBTRENDS = True
# Enable Google Analytics in production
#INCLUDE_ANALYTICS = True

try:
from .mounts_local import *
Expand Down

0 comments on commit 4eaf261

Please sign in to comment.