CodeCharge Studio
search Register Login  

Visual PHP Web Development

Visually Create Internationalized Web Applications, Web Reports, Calendars, and more.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> ASP

 FileUpload with UTF-8 filename

Print topic Send  topic

Author Message
solesz

Posts: 137
Posted: 01/27/2011, 3:34 AM

Hi,

I am a user from a country where accented letters are heavily used, like "őűúüóöáíé" etc.

I created a form, with an FileUpload control.
When I send the form, and upload happen, the name of a file is changed dramatically, in that way when I can not access its URL. Of course everything is in UTF-8.

For example:
original filename: abcdéáű.doc
uploaded filename: abcdeeA©A!A.doc

Obviously it is not good, even I can not download it. I am using ASP/VBscript upload, I tested with and without ADODB.stream, same result. Latest CCS 4.3 version is used.

Can somebody offer a solution, or at least confirm if the problem exists ?

Problem plus: if I put FileUpload into a form, where other form controls reside, then all UTF-8 content will be corrupted.

thx

solesz
View profile  Send private message
solesz

Posts: 137
Posted: 02/20/2011, 9:13 AM

Reply to myself,

I have already investigated:
- if form contains upload control (better to say: input field, type "file") then form processing MUST be binaryread (in ASP enviroment)
Once you open the POST data in binaryread, then you can't access the POST data in other way anymore.

It means, POST data, in binaryform has to processed by parsing. Look for file input, then read it, and stream it out to filesystem. Look for all other form control type, and read out the contain of formcontrols out of from binary data.

During this parsing everything has to be in UTF-8 to be able to read UTF-8 from form controls, from your web application.

This is, where CodeChargeStudio makes mistake.
- accept-charset has not flagged in form tag
- binaryread is reading in not UTF-8 stream, streamn object charset is not set to the specified charset
- small other mistake also

Then I changed the whole procedure to code found on : http://freeaspupload.net/
It's a bit unconvenient way, but it does what it has to.

Support ticket still open, several weeks ago. I really wainting answer from Yes. I will post my observations to them too.

solesz
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Web Database

Join thousands of Web developers who build Web applications with minimal coding.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.