Hello All,
I have pages like home, contact us, about us, that are on nearly every
webapp that I create. The other parts of the webapps are specific to
some business requirement, but the *us type pages are not. Unlike the
application pages proper, this supporting pages need to be updated
occasionally when the system is Live, and by non-programmers.
I could use a CMS, and then have links to my app on the pages. But, I
don't want to run a full blown CMS and Python/Django. And getting the
templates working in both seem like extra work.
I have searched a bit, and haven't found support for this. So I
thought I would roll my own (see below.) Does anyone else have this
need? How do you solve it?
class CMSPage
page_data =
page =
urls.py
(r'^about/$', 'about'),
views.py
def about(request):
page = CMSPages.objects.get(page='about')
return render_to_response('cms_page.html', {'page':page},
context_instance=RequestContext(request) )
cms_page.html
:
{{page.page_data}}
Then I can let the user edit the CMSPage via the admin. And, perhaps
I could even get TinyMCE or DOJO Editor going for them them.
I just want to check there isn't support for this sort of thing,
before I run of doing something custom.
thanks
Gene
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---