From: "Max R. Carrara" <m.carrara@proxmox.com>
To: "Michal Fox" <me@dualfroz.com>, <pve-devel@lists.proxmox.com>
Subject: Re: [PATCH manager] fix #6475: ui: upload: only show the file name of the selected file
Date: Mon, 28 Sep 2026 16:02:56 +0200 [thread overview]
Message-ID: <DLR07EIZEAX5.LP8NIPF5P7LL@proxmox.com> (raw)
In-Reply-To: <20260926084935.7-1-me@dualfroz.com>
On Sat Sep 26, 2026 at 10:49 AM CEST, Michal Fox wrote:
> For privacy reasons, browsers do not expose the real path of a selected
> file and prefix its name with 'C:\fakepath\' instead, on every
> platform. The file field of the upload window shows this value as is,
> which confuses users on Linux or macOS clients.
>
> Show the name of the selected file object instead. Only the displayed
> value changes, the upload itself uses the file object and is not
> affected.
>
> Signed-off-by: Michal Fox <me@dualfroz.com>
> ---
Gave this a spin on my workstation and can confirm that only the file's
name is displayed. Code also looks fine to me.
LGTM! Thanks a lot for your contribution!
Consider:
Reviewed-by: Max R. Carrara <m.carrara@proxmox.com>
Tested-by: Max R. Carrara <m.carrara@proxmox.com>
> www/manager6/window/UploadToStorage.js | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/www/manager6/window/UploadToStorage.js b/www/manager6/window/UploadToStorage.js
> index cc53596d..8010e127 100644
> --- a/www/manager6/window/UploadToStorage.js
> +++ b/www/manager6/window/UploadToStorage.js
> @@ -167,6 +167,8 @@ Ext.define('PVE.window.UploadToStorage', {
> (fileInput.files[0] && Proxmox.Utils.format_size(fileInput.files[0].size)) || '-',
> );
> vm.set('mimetype', (fileInput.files[0] && fileInput.files[0].type) || '-');
> + // browsers hide the real path behind 'C:\fakepath\', so only show the file name
> + input.setRawValue(fileInput.files[0]?.name ?? '');
> },
>
> hashChange: function (field, value) {
next prev parent reply other threads:[~2026-09-28 14:03 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-26 8:49 [PATCH manager] fix #6475: ui: upload: only show the file name of the selected file Michal Fox
2026-09-28 14:02 ` Max R. Carrara [this message]
2026-09-28 14:07 ` Max R. Carrara
2026-09-30 10:27 ` applied: " Dominik Csapak
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=DLR07EIZEAX5.LP8NIPF5P7LL@proxmox.com \
--to=m.carrara@proxmox.com \
--cc=me@dualfroz.com \
--cc=pve-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.