# place this snippet in your app's views.py file.# it assumes your app is called 'account', so change below as neededimportsysfromdjango.httpimportHttpResponse,HttpResponseRedirect,Http404fromdjango.shortcutsimportrender_to_responsedefroute_request(request,path,urlparams):parameters=urlparamsandurlparams[1:].split('/')or[]funcname='process_request__%s'%pathtry:function=getattr(sys.modules[__name__],funcname)exceptAttributeError:returnrender_to_response('account/%s.dj'%path,{'parameters':parameters})returnfunction(request,parameters)