Skip to content

Character encoding in multipart/form-data #39

@talp1

Description

@talp1

Hi Ste-gr,
I've tried your 1.5.0 RC2 and it's great! Finally Struts 1 in Jakarta EE9!

Only problem I have is with character encoding of text field in "multipart/form-data" forms, it's always ISO-8859-1, regardless of page encoding (I use UTF-8 everywhere).
For the moment I've bypassed the problem adding the line:

factory.setCharset(Charset.forName(request.getCharacterEncoding()));

in "org.apache.struts.upload:CommonsMultipartRequestHandler" after:

DiskFileItemFactory.Builder factory = DiskFileItemFactory.builder();

Maybe there is a cleanest solution via configuration, but I didn't find it :(

Can you tell me if it's possible to do them via configuration or if it could be useful to add my modification (perhaps improved) in the next release?

Thanks

Ale

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions