;> user_profile = Profile.objects.get(pk=1)
>>> attribute = 'name'
>>> getattr(user_profile, attribute)
> John
>
> Hope that helps, Mn
>
>
> On Oct 2, 10:47 am, WillF <[EMAIL PROTECTED]> wrote:
>> Hi I'm new to django. Is there way t
Hi I'm new to django. Is there way to get a specific column from a specific
table in a database when using Models. Say for instance I wanted just a list
of user's firstnames or something.
Also, with a instance of a Model, say for instance, UserProfile, is there a
way to get an arbitrary attribut
I have a Profile model that has a manytomany relationship with a model called
Group. When I look at the admin pages for a specific profile say for
instance 'testprofile'. For the Groups field I see the entire list of all
groups and not just the ones related to 'testprofile'.
Any ideas as to why
Okay Thanks.
So say for a login, should that be redirect?
Would there be a way to pass a context using the redirect much like
you can with render_to_response?
On Sep 18, 5:24 pm, Rajesh Dhawan <[EMAIL PROTECTED]> wrote:
> On Sep 18, 4:26 pm, WillF <[EMAIL PROTECTED]> wrote
Hi I currently have a page without a view. The corresponding url in the
url.py uses the generic view direct_to_template, is there any way I could
create a link to this url using the url template tag?
Thanks
--
View this message in context:
http://www.nabble.com/Possible-to-use-url-tag-to-direc
Hey I'm just picking django , and I have a question.
What is the difference between httpresponseredirect and render_to_response?
When should I use which?
Thanks!
--
View this message in context:
http://www.nabble.com/HttpResponseRedirect-or-render_to_response-tp19561038p19561038.html
Sent fr
David Durham, Jr. wrote:
>
>
> On Wed, Sep 17, 2008 at 1:35 PM, WillF <[EMAIL PROTECTED]> wrote:
>> I have written a login view as I have followed the tutorial but how do I
>> reuse this view in multiple pages of the site?
>>
>> Is there a way to r
I have written a login view as I have followed the tutorial but how do I
reuse this view in multiple pages of the site?
Is there a way to render this particular view as part of a template, so I
could have the login form (or anything for that matter) be displayed on
every single page?
--
View th
How does one get the domain the application is running on?
I have an email template where I pass in a url , obviously the url needs to
be fully qualified. How do i make it so that I do not have to hardcode the
domain, so the application can run on different environments without
changing anything
Hi I am new to django and python, and I have a question about best practices
with regards to applications. From what I understand applications should be
pluggable and portable to other "projects". So When do you know to start a
new application?
For instance if I am working on a social networking
10 matches
Mail list logo