gabrielrcouto / php-gui

Extensionless PHP Graphic User Interface library
2.24k stars 175 forks source link

Using InputFile for a single file #176

Closed jawira closed 3 years ago

jawira commented 5 years ago

Hello, I'm trying to use InputFile to load a single file, but I can't find a way to do it.

I was trying to reuse the code from one of the examples:

https://github.com/gabrielrcouto/php-gui/blob/7849019063a2513b6b865c09c97991d40e20ce18/examples/11-forms/02-example.php#L22-L28

I was hopping to force single file selection removing the following line:

https://github.com/gabrielrcouto/php-gui/blob/7849019063a2513b6b865c09c97991d40e20ce18/examples/11-forms/02-example.php#L27

But it turns out that the example doesn't work correctly any more, now \Gui\Components\InputFile::getValue will always return an empty array, even when a file is selected.

Is this a bug, or am I doing something wrong?

jawira commented 3 years ago

Sad, this project seems abandoned 🪦