Form uploads index.html instead of test.doc

Aleksa 14 Sep, 2010
Hello.

On my websites I use ChronoForm with an upload field. Everything worked fine until 2 weeks ago. Since then everytime someone is uploading a file it does not get saved as the date_filename.fileextention anymore but a index.html with just NULL in gets uploaded. The next time someone uploads a file this index.html gets overwritten.

There is no error or anything while uploading.

Can somebody please give a hint in some direction, as I do not know where to look anymore. Thanks a mil.
GreyHead 14 Sep, 2010
Hi Aleksa,

Sorry, I've no idea, I don't remember this being reported before.

Please can you post a link to the form so that I can take a quick look.

Please will you also check with your web host to make sure that they haven't made any changes that might affect this.

Bob
Aleksa 15 Sep, 2010
Here the settings, maybe there is something wrong?

Form uploads index.html instead of test.doc image 1

and the ones from the File upload

Form uploads index.html instead of test.doc image 2

this is what I get via Email

Form uploads index.html instead of test.doc image 3

and this is what happens in the folder the uploaded files where normaly saved. Everything fine until 31.Aug and after that it just updated the index.html that has just a NULL in it.

Form uploads index.html instead of test.doc image 4

Any ideas?
Thanks a mil.
GreyHead 15 Sep, 2010
Hi Aleksa,

Nothing obviously wrong there - but then there shouldn't be as the form was working OK last month.

Please turn on Form Debug, submit the form and copy and paste all the debug info here.

What did your web-host have to say?

Bob
Aleksa 16 Sep, 2010
Thanks for looking at it. Its really strange and I need this form to work. He the Debug:

1. Form passed first SPAM check OK
2. Form passed the submissions limit (if enabled) OK
3. Form passed the Image verification (if enabled) OK
4. Form passed the server side validation (if enabled) OK
5. $_POST Array: Array ( [text_0] => Aleksa Test [text_1] => [email]xxx@xxx.co.za[/email] [select_4] => Origins and Diversity [select_7] => Oral [button_3] => Submit [6f5e9fc3cd0e554291306ad0bad5b7fa] => 1 [1cf1] => 6de3d96de7bffdf31fdca27ab503c50d [chronoformname] => upload )
6. $_FILES Array: Array ( [file_2] => Array ( [name] => testfile.doc [type] => application/msword [tmp_name] => /usr/home/rgcutq/.tmp/phpDDhsl3 [error] => 0 [size] => 21504 ) )
7. Form passed the plugins step (if enabled) OK
8. An email has been SENT successfully from (RGC5)xxx@xxx.co.za to [email]xxx@xxx.co.za[/email]
9. Debug End

By the way, the Hosting Comany says that no changes where made this month.
Aleksa 16 Sep, 2010
I actually now wanna put my head under ground. I found the error. Thanks for telling me to put on Debug. As some people say, to many cooks ...

It was a naming issue. The form tried to send file_2 but everything was names file_1 ...

Sorry again ... and thanks for all the help.
GreyHead 16 Sep, 2010
Hi Aleksa,

Glad you got it fixed, easy mistake to make and hard to spot :-)

Bob

PS Troubleshooting problems with files is explained in more detail in Chapter 8 of The ChronoForms Book
This topic is locked and no more replies can be posted.