Andres Vargas avatar Andres Vargas committed bb10ca9

update templates and settings

Comments (0)

Files changed (6)

+*.pyc
+.*.sw*
+*.db

fartapp/context_processor.py

+from django.contrib.sites.models import get_current_site
+from django.conf import settings
+
+def default(request):
+    return {
+        'SITE':get_current_site(request),
+        'FACEBOOK_ID':settings.FACEBOOK_ID,
+        'FACEBOOK_SECRET_KEY':settings.FACEBOOK_SECRET_KEY,
+        'FACEBOOK_NAMESPACE':settings.FACEBOOK_NAMESPACE,
+    }

fartapp/settings.py

     # 'django.middleware.clickjacking.XFrameOptionsMiddleware',
 )
 
+from django.conf import TEMPLATE_CONTEXT_PROCESSORS
+
+TEMPLATE_CONTEXT_PROCESSORS += ('context_processor.default',) 
+
+
 ROOT_URLCONF = 'fartapp.urls'
 
 # Python dotted path to the WSGI application used by Django's runserver.
     'django.contrib.sites',
     'django.contrib.messages',
     'django.contrib.staticfiles',
-     'django.contrib.admin',
+    'django.contrib.admin',
+    'south',
 )
 
 # A sample logging configuration. The only tangible logging
         },
     }
 }
+
+FACEBOOK_API_KEY= ''
+FACEBOOK_ID= FACEBOOK_API_KEY
+FACEBOOK_SECRET_KEY = ''
+FACEBOOK_NAMESPACE = ''
+

fartapp/templates/base.html

 
   <body>
 
-    <div class="navbar navbar-inverse navbar-fixed-top">
-      <div class="navbar-inner">
-        <div class="container">
-          <a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
-            <span class="icon-bar"></span>
-            <span class="icon-bar"></span>
-            <span class="icon-bar"></span>
-          </a>
-          <a class="brand" href="#">Project name</a>
-          <div class="nav-collapse collapse">
-            <ul class="nav">
-              <li class="active"><a href="#">Home</a></li>
-              <li><a href="#about">About</a></li>
-              <li><a href="#contact">Contact</a></li>
-            </ul>
-          </div><!--/.nav-collapse -->
-        </div>
-      </div>
-    </div>
 
     <div class="container">
 
-      <h1>Bootstrap starter template</h1>
-      <p>Use this document as a way to quick start any new project.<br> All you get is this message and a barebones HTML document.</p>
+<div class="row">
+    <div class="span2">
+      <!--content-->
+    </div>
+    <div class="span8">
+      {%block content %}
+      {% endblock %}
+    </div>
+    <div class="span2">
+      <!--content-->
+    </div>
+  </div>
+
 
     </div> <!-- /container -->
   </body>

fartapp/templates/index.html

+{% extends 'base.html'%}
+{%block content %}
+
+
+
+      <h1>Bootstrap starter template</h1>
+      <p>Use this document as a way to quick start any new project.<br> All you get is this message and a barebones HTML document.</p>
+
+{% endblock %}
 from django.views import generic
 
 class Base(generic.TemplateView):
-    template_name = "base.html"
-
+    template_name = "index.html"
 
 index = Base.as_view()
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.