On Oct 20, 2008, at 8:11 AM, truebosko wrote:

> What is happening: The custom upload handler works, data is being
> sent, the session is being set WITHIN the handler but when I call the
> function from Javascript to fetch the progress (or even from a simple
> manual GET) it does not return anything because it does not recognize
> the session
>
> What I found though, is that the view that is being called from JS
> will finally have access to the session variable after the upload is
> complete which in this case makes it totally useless since I'm trying
> to track the progress and not just show them "Uploading ..."

[...]

> So that's where I stand now at this. The progress view just cant get
> the request.session variable. It shows up, eventually but not when I
> need it. I figure I might be doing something silly but I don't know
> anymore

Yes, I think you are. :^) The session is saved at the end of the  
request. That's why your progress report view doesn't see anything  
until the upload completes.

You could explicitly save the session every chunk and batter your  
database, but the cache is a better place for this.

John

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to