[BangPypers] Acessing session variables in template with django
look4puneet at gmail.com
Sat May 23 17:20:59 CEST 2009
Thanks Gora, Praveen,
Its working for me now.
On Sat, May 23, 2009 at 8:15 AM, Praveen Kumar <
praveen.python.plone at gmail.com> wrote:
> First of all refer the doc of Django what Gora suggested you.
> Use the print statement or pdb to trace the line.
> I have doubt in the line
> request.session['cityname'] = *cityname*
> you should write request.session['cityname'] = *request*.POST[cityname]
> or just check the value of cityname.
> On Sat, May 23, 2009 at 1:01 PM, Gora Mohanty <gora at srijan.in> wrote:
>> On Sat, 23 May 2009 11:03:26 +0530
>> Puneet Aggarwal <look4puneet at gmail.com> wrote:
>> > Hi All,
>> > I am facing issue when I am trying to access session variables in
>> > I am setting the session variable something like :
>> > request.session['cityname'] = cityname
>> This should work. Have you set MIDDLEWARE_CLASSES properly
>> in settings.py, and added django.contrib.sessions to your
>> INSTALLED_APPS? See the top of
>> or the appropriate documentation version for your Django
>> BangPypers mailing list
>> BangPypers at python.org
> Praveen Kumar
> +91 9739854134
> BangPypers mailing list
> BangPypers at python.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the BangPypers