Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do you pass or share variables between django views?

I'm kind of lost as to how to do this:

I have some chained select boxes, with one select box per view. Each choice should be saved so that a query is built up. At the end, the query should be run.

But how do you share state in django? I can pass from view to template, but not template to view and not view to view. Or I'm truly not sure how to do this. Please help!

like image 224
Hugh Avatar asked Apr 03 '10 03:04

Hugh


1 Answers

Put the values to hold into the session.

like image 139
Ignacio Vazquez-Abrams Avatar answered Sep 16 '22 20:09

Ignacio Vazquez-Abrams