[web2py] Re: [web2py:8670] Re: Video Upload: Validate as video file, convert to flv, 'best practice' method?

2012-06-04 Thread Charles Tang
The temporary uploaded video file does not appear in uploads directory until the video is completely uploaded. So is it possible to access the temporary video file when the file is being uploading ?Thanks! On Friday, August 29, 2008 9:12:35 PM UTC+8, Massimo Di Pierro wrote: > > follow-up > > --

[web2py] Re: access an uploaded but not stored file?

2012-06-04 Thread Charles Tang
I have the same problem. How did you sovle it? On Saturday, January 15, 2011 8:56:41 AM UTC+8, Thomas Dall'Agnese wrote: > > Dear community, > > I have a form with an upload field that I use to upload a text file, > parse information from this file and store this information into the > database

[web2py] How to access temporary uploaded file?

2012-06-04 Thread Charles Tang
I am using a sqlform to upload a video file and want to encoding the video file while uploading. But I noticed that the upload file is not saved to uploads directory utill it is completely uploaded. Is there a temporary file and how can I access it ?Thanks.

[web2py] How to access temporary uploaded files and its filename?

2012-06-04 Thread Charles Tang
I want to encoding video files while uploading. The webpage should display the uploading process and encoding process. I use this snippet of codeto display the uploading progress and it works. But I found the video file wou

[web2py] Re: How to access temporary uploaded file?

2012-06-04 Thread Charles Tang
a while, you might want to pass it off to a task queue > rather than handle it in the controller. > > Anthony > > On Monday, June 4, 2012 4:23:55 AM UTC-4, Charles Tang wrote: >> >> I am using a sqlform to upload a video file and want to encoding the >> vide

[web2py] Re: access an uploaded but not stored file?

2012-06-04 Thread Charles Tang
Can the request.vars.file_fileid.file be accessed before the video is completely uploaded? On Monday, June 4, 2012 11:36:35 PM UTC+8, Massimo Di Pierro wrote: > > The file is in request.vars.file_field.file which is a read-only stream. > You can shutil.copyfile it to a temporary folder. > > On F

[web2py] Re: access an uploaded but not stored file?

2012-06-04 Thread Charles Tang
I have test request.vars.file_field.file, it can only be accesssed after the whole file is uploaded.Should I do it at a lower level? On Tuesday, June 5, 2012 11:41:28 AM UTC+8, Charles Tang wrote: > > Can the request.vars.file_fileid.file be accessed before the video is > completely

[web2py] Re: access an uploaded but not stored file?

2012-06-05 Thread Charles Tang
stream (contains the multipart > form, which may have files in it) > - cgi.FieldStorage(fp=request.body) parses the request stream and return a > dictionary of FieldStorage objects (including files that may be in there) > > Perhaps this helps. > > > > > > On Monday, 4 J

[web2py] How to limit upload speed in web2py?

2012-06-06 Thread Charles Tang
I am using SQLForm to submit a large file and want to limit the upload speed. How to do it ? Thanks.

[web2py] Why the temporary file is larger than the original one?

2012-06-06 Thread Charles Tang
I am uploading a video from using web2py SQLFORM and want to process it while it is uploading. I find that even the video is completely uploaded the temporary file of the video in the /tmp directory is larger than the original video.Why?Does the python tempfile module add some bytes to it?Many

Re: [web2py] How to limit upload speed in web2py?

2012-06-11 Thread Charles Tang
What do you mean about the webserver config? Where is it in web2py? On Wednesday, June 6, 2012 11:15:42 PM UTC+8, sebastian wrote: > > via your webserver config... > > On Wed, Jun 6, 2012 at 8:14 AM, Charles Tang wrote: > >> I am using SQLForm to submit a large file and wan

[web2py] How to play flv video files in web2py?

2012-06-12 Thread Charles Tang
I am using web2py to play user's uploaded video file encoding with different encoding params.Only the original uploaded video is in db and it can be accessed and played using code below: var flashvars = {}; flashvars.myurl = "{{=URL('download', ar

[web2py] How to prevent the default SQLFORM submit when the upload is complete and wait?

2012-06-13 Thread Charles Tang
I am using sqlform to upload a video and in the meantime converting the video to flv .Both the progress of uploading and encoding is displayed by two progress-bar using this code(http://www.web2pyslices.com/slice/show/1337/upload-progress-in-web2py). After the encoding and converting is both co

[web2py] Re: How to prevent the default SQLFORM submit when the upload is complete and wait?

2012-06-13 Thread Charles Tang
ler code? > > On Wednesday, June 13, 2012 6:56:12 AM UTC-4, Charles Tang wrote: >> >> I am using sqlform to upload a video and in the meantime converting the >> video to flv .Both the progress of uploading and encoding is displayed by >> two progress-bar using t

[web2py] Re: How to prevent the default SQLFORM submit when the upload is complete and wait?

2012-06-13 Thread Charles Tang
The encoding happens at backend and progresss is displayed by ajax request. On Thursday, June 14, 2012 10:51:15 AM UTC+8, Anthony wrote: > > Where is the encoding happening? > > On Wednesday, June 13, 2012 10:24:33 PM UTC-4, Charles Tang wrote: >> >> The controller code

[web2py] Re: How to prevent the default SQLFORM submit when the upload is complete and wait?

2012-06-13 Thread Charles Tang
I did some hacking in the copystream in gluon/main.py and begin encoding with ffmpeg from the temporary file onece it detect video upload is happen.

[web2py] Re: How to prevent the default SQLFORM submit when the upload is complete and wait?

2012-06-13 Thread Charles Tang
SQLFORM(db.encodeupload) > if upload_form.validate(): > [while loop checking to see if file encoding is complete] > db.encodeupload.insert(**form.vars) > [rest of code] > > Anthony > > On Wednesday, June 13, 2012 11:24:09 PM UTC-4, Charles Tang wrot