]> git.openstreetmap.org Git - osqa.git/blobdiff - forum/views/meta.py
Fixing some encoding/decoding errors, including the akismate module, and fixed the...
[osqa.git] / forum / views / meta.py
index fc050c218e013cd7882bd97ffeca4d802a4cdf29..bae96f2c7bf7b0fa5e3a88359d2bc27d32504522 100644 (file)
@@ -1,8 +1,10 @@
+import os
 from itertools import groupby
 from django.shortcuts import render_to_response, get_object_or_404
 from django.core.urlresolvers import reverse
 from django.template import RequestContext, loader
 from django.http import HttpResponseRedirect, HttpResponse
+from django.views.static import serve
 from forum import settings
 from forum.forms import FeedbackForm
 from django.core.urlresolvers import reverse
@@ -21,6 +23,17 @@ def favicon(request):
 def static(request, title, content):
     return render_to_response('static.html', {'content' : content, 'title': title}, context_instance=RequestContext(request))
 
+def media(request, skin, path):
+    return serve(request, "%s/media/%s" % (skin, path), 
+                 document_root=os.path.join(os.path.dirname(os.path.dirname(__file__)),'skins').replace('\\','/'))
+
+def markdown_help(request):
+    # md = markdown.Markdown([SettingsExtension({})])
+    # text = md.convert(settings.FAQ_PAGE_TEXT.value)
+
+    return render_to_response('markdown_help.html', context_instance=RequestContext(request))
+
+
 def opensearch(request):   
     return render_to_response('opensearch.html', {'settings' : settings}, context_instance=RequestContext(request))