Fixing uploads in firefox.

This gets around a limitation in flash (known manifistation in Firefox) where you can't insert the cookie directly into the header of the request.