Re: best practices for creating a template/theming layer for users in a django app

2010-03-04 Thread gdup
Thanks! Ill give it a try On Mar 4, 11:04 am, Nick wrote: > sorry, let me rewrite that last part > > render_to_response ('%s/index.html' u'theme', {'dictionary': > dictionary}) > > On Mar 4, 12:11 am, Nick wrote: > > > It seems like this would be best handled at the view level, you could > > pas

Re: best practices for creating a template/theming layer for users in a django app

2010-03-04 Thread Nick
sorry, let me rewrite that last part render_to_response ('%s/index.html' u'theme', {'dictionary': dictionary}) On Mar 4, 12:11 am, Nick wrote: > It seems like this would be best handled at the view level, you could > pass a url variable in the render_to_response portion, maybe something > like >

Re: best practices for creating a template/theming layer for users in a django app

2010-03-03 Thread Nick
It seems like this would be best handled at the view level, you could pass a url variable in the render_to_response portion, maybe something like def theme(request): # a bunch of view display stuff theme = ThemeModel.objects.get('template__name') if theme: render_to_response('%s'

Re: best practices for creating a template/theming layer for users in a django app

2010-03-03 Thread Nick
Ideally what you'd want to do is handle all of this On Mar 3, 6:12 pm, gdup wrote: > O crap! that sounds about right. I was thinking of media_url in terms > of only static files, didnt think of {{ templatename }} variable. > > As for the templating part in an app like shopify , i am not familar >

Re: best practices for creating a template/theming layer for users in a django app

2010-03-03 Thread gdup
O crap! that sounds about right. I was thinking of media_url in terms of only static files, didnt think of {{ templatename }} variable. As for the templating part in an app like shopify , i am not familar with rails, but i assume it allows you to create custom template tags like django. I doubt th

Re: best practices for creating a template/theming layer for users in a django app

2010-03-03 Thread Nick
If I'm understanding what you're asking, it should be as simple as adding an entry per user that designates the template/theme you'd like to use and then passing that as a variable (ex. {{ MEDIA_URL }} {{ templatename }} where template name would be the directory name of the template. Let me know

best practices for creating a template/theming layer for users in a django app

2010-03-03 Thread gdup
Hello all, I would really aprreciate it if someone could point me in the right direction of creating a themeing and template layer for an application written in django, similar to what tumblar and shopify do. I can almost put my finger on the whole concept. I know u can somehow serve the MEDIA_UR