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<br />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<br />well it doesn 't encoded in the write way i will put all the code, from the area whats take the environ['wsgi.input'] to the area<br />thats save the file:<br /><br />tmpData = str(rawData)[1:].strip("' '")#Here the data from the environ['wsgi.input'], first i convert the byte into a string delete the first field that represent the b and after i strip the single quotes<br />dat = tmpData.split('\\r')#Then i split all the data in the '\\r'<br />s = open('/home/hidura/test.png', 'w')#I open the test.png file.<br />for cont in range(5,150):#Now beging in the 5th position to the 150th position <br />       s.write(dat[cont])#Insert the piece of the data in the file.<br />s.close()#Then closed.<br /><br />Where is the mistake?<br /><br />Thankyou in advance.<br /><br />--<br />Diego Hidalgo D.