Re: Re: Re: Problem saving uploaded files in Python3

2010-10-04 Thread hidura
This is the code what i use to save the file. tmpData = str(rawData)[1:].strip("' '") tmp = tmpData.split('\\r') for piece in tmp: for slice in piece.split('\n'): if 'Content-Disposition' in slice: filename = slice.split(';')[2].split('=')[1] h = open('home/hidura/'+filename.strip('" "'), 'wb') el

Re: Re: Problem saving uploaded files in Python3

2010-10-02 Thread hidura
The results was that, i can upload all the data normally comes as an byte code and looks like this: \\n\\x1a\\n\\x00\\x00\\x00IHDR\\x00\\x00\\x05U\\x00\\x00\\x026\\x08\\x06\\x00\\x00\\x00P]h\\xc5\\x00\\x00\\x00\\x01sRGB\\x00\\xae\\xce\\x1c\\xe9\\x00\\x00\\x00\\x06bKGD\\x00\\xff\\x00\\xff\\x00\\

Re: Problem saving uploaded files in Python3

2010-10-02 Thread Diez B. Roggisch
Chris Rebert writes: > On Fri, Oct 1, 2010 at 11:13 PM, wrote: >> Hello, i control the problem of the data what is uploaded by the POST >> method, in the web if the file is a text theres no problem >> but the trouble comes when it's an enconded file as a Picture or other what >> the when the sy

Re: Problem saving uploaded files in Python3

2010-10-01 Thread Chris Rebert
On Fri, Oct 1, 2010 at 11:13 PM, wrote: > Hello, i control the problem of the data what is uploaded by the POST > method, in the web if the file is a text theres no problem > but the trouble comes when it's an enconded file as a Picture or other what > the when the system insert the data into the

Problem saving uploaded files in Python3

2010-10-01 Thread hidura
Hello, i control the problem of the data what is uploaded by the POST method, in the web if the file is a text theres no problem but the trouble comes when it's an enconded file as a Picture or other what the when the system insert the data into the file well it doesn 't encoded in the write wa