file upload from a form, Trying to find full path name for an uploading file |
file upload from a form, Trying to find full path name for an uploading file |
jalguire |
Jul 14 2012, 08:17 PM
Post
#1
|
Group: Members Posts: 3 Joined: 14-July 12 Member No.: 17,440 |
When using a form to upload a file via PHP, it appears that the browser user agent does some internal processing and only provides the actual file name, without the full path name, to the PHP global $_FILE. I have looked at most all the PHP server-side globals and have not as yet found any mention of the path to the uploading file.
It seems to me that this information must be available somewhere to enable the browser, via the form, to upload the file to the server. If anyone knows where this path information is hiding and how it might be accessed, I sure would appreciate knowing to find it. Thanks, Jim |
Christian J |
Jul 15 2012, 07:05 AM
Post
#2
|
. Group: WDG Moderators Posts: 9,656 Joined: 10-August 06 Member No.: 7 |
It should be kept hidden by the UA for security reasons.
|
jalguire |
Jul 15 2012, 12:56 PM
Post
#3
|
Group: Members Posts: 3 Joined: 14-July 12 Member No.: 17,440 |
It should be kept hidden by the UA for security reasons. Christian, thanks for the reply. Apparently not all UAs are concerned with security. Safari and Chrome both conceal the path to the file, but Firefox and Opera display it in a text box for all to see. This on the Mac. Jim |
Christian J |
Jul 15 2012, 02:08 PM
Post
#4
|
. Group: WDG Moderators Posts: 9,656 Joined: 10-August 06 Member No.: 7 |
True, but it isn't sent along with the form submission. Javascript shouldn't be able to access the file text field's content either.
|
jalguire |
Jul 15 2012, 07:54 PM
Post
#5
|
Group: Members Posts: 3 Joined: 14-July 12 Member No.: 17,440 |
|
Lo-Fi Version | Time is now: 23rd April 2024 - 01:52 AM |