yes, django has session management, but why would you need to do that based on session? I mean, you could just get a different content every time you render the page, of course showing something in random have a chance of repeating the same, if you have no control on what was already shown to the current person if you want to be 100% that you won't show the same food for the same person when he reloads the page you would need to store the history and tie that to the user or session.
but in my opinion is not worth the overhead, it is not so bad to have a small % of repeats On Thu, Dec 19, 2013 at 11:00 PM, Chen Xu <xuche...@gmail.com> wrote: > I am currently working on a web page using Django to recommend people > food, basically when people refresh the page, it shows a different food > which is from the database. I am wondering if there is a way to show > different food every time when people refresh (people dont need to login), > does Django provide some sort of session? > > > Thanks in advance > > -- > ⚡ Chen Xu ⚡ > > -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to django-users+unsubscr...@googlegroups.com. > To post to this group, send email to django-users@googlegroups.com. > Visit this group at http://groups.google.com/group/django-users. > To view this discussion on the web visit > https://groups.google.com/d/msgid/django-users/CACac-qaKYJfARKv08Y9QUUYW27hLr6a9__K%2BY4EMi-%3D8d-z6Cg%40mail.gmail.com > . > For more options, visit https://groups.google.com/groups/opt_out. > -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To post to this group, send email to django-users@googlegroups.com. Visit this group at http://groups.google.com/group/django-users. To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAFWa6t%2BmRgbEih9cge-ETTfX_RaSKkh8H1_ufTPR2kRXbYGMrQ%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.