Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 6 of 6 total
Thread image upload using TFileComboBox problem
Mon, Aug 7 2017 7:49 PMPermanent Link

KimHJ

Comca Systems, Inc

I'm properly doing something wrong.

I use a THTMLForm with a TFileComboBox and some TEdit.
When I run it in the EWB it works fine , I select an image and the whole path shows in the TFileComboBox.

When I run the same app on the webserver in the cloud, after selecting the image I only get the image name and extension. I'm missing the path, with the result I can't upload it.

Is this normal?

Do I need to grab the path somewhere?

Thanks,
Kim
Tue, Aug 8 2017 2:11 AMPermanent Link

Mark Brooks

Slikware

Avatar

I think this is normal behaviour. Some browsers reveal the path and some do not, however the upload should still work. Have you tried?
Tue, Aug 8 2017 10:28 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Kim,

<< Is this normal?  >>

Yes.  The path returned from any file upload control in a web browser application will depend completely upon the browser, so you should *always* strip out any path that is included in the file name on the web server when receiving the file upload as a MIME part.

Actually, I should just change EWB to strip out the path information on the browser side.  It's irrelevant, and a bit of an information leak for the client machine.

Tim Young
Elevate Software
www.elevatesoft.com
Tue, Aug 8 2017 6:37 PMPermanent Link

KimHJ

Comca Systems, Inc

Mark Brooks wrote:

>>I think this is normal behaviour. Some browsers reveal the path and some do not, however the upload should still >>work. Have you tried?

I didn't try first, but it did work thanks.
Tue, Aug 8 2017 7:31 PMPermanent Link

KimHJ

Comca Systems, Inc

Tim Young [Elevate Software] wrote:

>>Actually, I should just change EWB to strip out the path information on the browser side.  It's irrelevant, and a bit >>of an information leak for the client machine.

I was looking for how to strip it out on the browser side but didn't found a solution.

Kim
Wed, Aug 9 2017 10:00 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Kim,

<< I was looking for how to strip it out on the browser side but didn't found a solution. >>

That's a good point - due to security restrictions it may not be possible for EWB to modify what the browser has set for the file information.

Tim Young
Elevate Software
www.elevatesoft.com
Image