]> git.sommitrealweird.co.uk Git - sommitrealweird.git/commitdiff
Change / to Home in breadcrumb
authorBrett Parker <iDunno@sommitrealweird.co.uk>
Fri, 27 Mar 2009 14:55:05 +0000 (14:55 +0000)
committerBrett Parker <iDunno@sommitrealweird.co.uk>
Fri, 27 Mar 2009 14:55:05 +0000 (14:55 +0000)
sommitrealweird/blog/context_processors.py
sommitrealweird/bpcms/context_processors.py

index 14a921609d37a8b65a022b76d7d2cc37eb5fd18f..e63a85f24b4e4f89cc4a360c8f60790016d730f0 100644 (file)
@@ -5,7 +5,7 @@ import re
 def content_breadcrumb(request):
     path = request.path
     if path[0:len(settings.BLOG_ROOT)] == settings.BLOG_ROOT:
-        breadcrumb = [{'url': u'/', 'title': u'/'}, {'url': settings.BLOG_ROOT, 'title': u'blog'},]
+        breadcrumb = [{'url': u'/', 'title': u'Home'}, {'url': settings.BLOG_ROOT, 'title': u'blog'},]
 
         path = path[len(settings.BLOG_ROOT):]
 
index 3668ab008dfdb475cf6400ec7b900b1a1c7318e9..a78976df893f1f919eff7a92b6f959b431bcb3b5 100644 (file)
@@ -101,7 +101,10 @@ def content_submenu(request):
     }
 
 def content_breadcrumb(request):
-    breadcrumb = [{'url': settings.BPCMS_ROOT, 'title': settings.BPCMS_ROOT},]
+    if settings.BPCMS_ROOT == "/":
+        breadcrumb = [{'url': settings.BPCMS_ROOT, 'title': "Home"}]
+    else:
+        breadcrumb = [{'url': settings.BPCMS_ROOT, 'title': settings.BPCMS_ROOT},]
     # find where we are in the tree first
     folderpath = request.path
     folderpath = re.sub(u'^%s' %(settings.BPCMS_ROOT), '', folderpath)