Forums

Error uploading file

walterbz 17 May, 2022
Hi all.
I made a simple form with just an upload file.
Using Joomla 4.
The result is always this error message:

Warning: Trying to access array offset on value of type null in myserverpath/administrator/components/com_chronoforms7/chronoforms/functions/upload/upload_output.php on line 27

Also the file name in debug is empty
Array
(
    [option] => com_chronoforms7
    [cont] => manager
    [chronoform] => form-17may22-1427
    [gpage] => end_page
    [__cf_token] => 83ed41c0-51c3-4d9c-8ebf-f2c0602c2674
    [file_1] => 
)

Any idea?
Thanks
Colnem 17 May, 2022
Hi

Please, share your form...
walterbz 17 May, 2022
here it is thanks
​[file=https://ebk.pixxdb.net/uploadfile_17_May_2022_17%2032%2014.cf7bak]https://ebk.pixxdb.net/uploadfile_17_May_2022_17%2032%2014.cf7bak[/file]
Colnem 17 May, 2022
OK

It works very well for me, after a little correction...

In Settings, Upload Files, you write this...
/var/www/vhosts/area-shop.com/httpdocs/ebk/

I suppose that you want to upload file in folder /httpdocs/ebk/ of your domain area-shop.com
In this case, you have to write...
{path:root}/httpdocs/ebk/

In another case, write me in what folder you want to upload your file.

Good luck...
walterbz 17 May, 2022
Tried also with this change but always same error. Are you using Joomla 4?
Colnem 17 May, 2022
Yes, I'm using Joomla 4 and CF7.

But you haven't answer to my question.
Have you a folder named /httpdocs/ebk/ at the root of your site?
Colnem 17 May, 2022
Sorry but there is an error in your form...

Look at the debug.
I read
[path] => \var\www\vhosts\area-shop.com\httpdocs\ebk\
If I don't modify your form, I have the same error than you...

If you modify Settings of the form like I said ({path:root}/upload/files/), you should have..


[path] => https:/ebk.pixxdb.net/upload/files/

walterbz 17 May, 2022
it's exactly what you wrote:
Colnem 18 May, 2022
OK

I suppose that your folder /upload/files/ exists at the root of your site...

1: Backup your form
2: Delete your form
3: Clear Joomla Cache and Chronoforms Cache
4: Restore your form
5: Retry...
walterbz 18 May, 2022
Answer
Thanks Colnem, but the solution was easier that thought.
The allowed file extension was missing in Chronoforms general settings (not in single form setting).
I found it debugging the whole upload script.
The bug is that it should give an error.
You need to login to be able to post a reply.