It ended up being an encoding issue.
In the application, I had woresponse that was setting the encoding to UTF8 
instead of UTF-8.

Thanks,
Harjinder Singh | Sr Programmer Analyst
t. 416-479-9710 |  e. 
harjind...@portfolioaid.com<mailto:harjind...@portfolioaid.com>

PortfolioAid | website<http://portfolioaid.com/>  |  
linkedin<http://linkd.in/18SQTYR>  |  twitter<https://twitter.com/portfolioaid>
166 Pearl Street, Suite 200, Toronto, ON M5H 1L3

2020 WealthTech100 Company<https://fintech.global/wealthtech100/>  |  2020 WP 
Awards Service Provider of the Year (finalist<https://wpawards.ca/>)

This e-mail may be privileged and confidential. If you received this e-mail in 
error, please do not use, copy, or distribute, but advise me immediately
(by return e-mail or otherwise), and delete the e-mail. PortfolioAid is 
committed to taking all reasonable measures to safeguard your confidential 
client
information. When sending attachments and/or screenshots to the PortfolioAid 
Help Desk or other PortfolioAid personnel, we kindly remind you to omit,
redact or securely protect any personally identifiable client information (e.g. 
name, address, SIN, date of birth, etc.)

From: Harjinder Singh via Webobjects-dev [mailto:webobjects-dev@lists.apple.com]
Sent: August 25, 2020 11:15 PM
To: WebObjects Development <webobjects-dev@lists.apple.com>
Subject: Default form value encoding was changed after parsing multi-part form. 
Form values will be lost.

Hi All,

I am working on introducing wonder in one of our applications. In the app  
there  is a component that allows the user to upload files.
It's using WOFileUpload with form using enctype = "multipart/form-data";

It works with regular webobjects but when I introduce project wonder something 
goes wrong with the form submission.
It does not submit anything and just refreshes the page. I don't get any errors 
anywhere. I need "multipart/form-data" for uploading to work. Without it form 
is working correctly.

I did some digging and found the same issue 
https://lists.apple.com/archives/webobjects-dev/2009/Sep/msg00477.html.

As in the issue from 2009, I removed WOFileUpload and tried submitting the 
form. In that case I am getting the error as below:

IllegalStateException: Default form value encoding was changed after parsing 
multi-part form. Form values will be lost.
  at 
com.webobjects.appserver.WORequest.setDefaultFormValueEncoding(WORequest.java:767)
  at 
er.extensions.appserver.ERXMessageEncoding.setDefaultFormValueEncodingToRequest(ERXMessageEncoding.java:174)
  at 
er.extensions.appserver.ERXMessageEncoding.setDefaultFormValueEncodingToRequest(ERXMessageEncoding.java:179)
     ... skipped 3 stack elements
  at 
er.extensions.appserver.ERXComponentRequestHandler._dispatchWithPreparedPage(ERXComponentRequestHandler.java:150)
  at 
er.extensions.appserver.ERXComponentRequestHandler._dispatchWithPreparedSession(ERXComponentRequestHandler.java:235)
  at 
er.extensions.appserver.ERXComponentRequestHandler._dispatchWithPreparedApplication(ERXComponentRequestHandler.java:268)
  at 
er.extensions.appserver.ERXComponentRequestHandler._handleRequest(ERXComponentRequestHandler.java:302)
  at 
er.extensions.appserver.ERXComponentRequestHandler.handleRequest(ERXComponentRequestHandler.java:375)


In the properties file I am setting 
er.extensions.ERXApplication.DefaultEncoding=UTF-8

But it is still not working for me and gives me the same error as above (when I 
remove wofileupload).

Why is encoding not working? Do I setup encoding elsewhere?

Or Is the issue elsewhere in my case?

Any help is greatly appreciated.

Webobjects version : 5.4.3
Java version  :    8


Thanks,

Harjinder Singh | Sr Programmer Analyst
t. 416-479-9710 |  e. 
harjind...@portfolioaid.com<mailto:harjind...@portfolioaid.com>

PortfolioAid | website<http://portfolioaid.com/>  |  
linkedin<http://linkd.in/18SQTYR>  |  twitter<https://twitter.com/portfolioaid>
166 Pearl Street, Suite 200, Toronto, ON M5H 1L3

2020 WealthTech100 Company<https://fintech.global/wealthtech100/>  |  2020 WP 
Awards Service Provider of the Year (finalist<https://wpawards.ca/>)

This e-mail may be privileged and confidential. If you received this e-mail in 
error, please do not use, copy, or distribute, but advise me immediately
(by return e-mail or otherwise), and delete the e-mail. PortfolioAid is 
committed to taking all reasonable measures to safeguard your confidential 
client
information. When sending attachments and/or screenshots to the PortfolioAid 
Help Desk or other PortfolioAid personnel, we kindly remind you to omit,
redact or securely protect any personally identifiable client information (e.g. 
name, address, SIN, date of birth, etc.)

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to