Forums

missing closing PHP tag at file upload

seppo 23 May, 2016
If I add the File Upload action, there is a field "File name code" automatically inserted. One odd thing is that it cannot be edited there at the textarea. But that was (maybe) not the bug here.

In that area, it is autofilled with:
<?php return date("YmdHis")."_".$file_name;

But it is missing closing PHP -tag: ?>

I suppose it should be there?
I did change that to file_upload.php (at line 212), but that didn't help to solve yet my problem of file is not uploading nor giving any message from Display Message -event boxes.

Anyway, while fixing that did not solve my problem yet, I thought it might be a bug anyway to report. And in either case, I guess that field should be editable?

Cheers.
GreyHead 24 May, 2016
Hi seppo,

A closing PHP tag is optional, I almost always add them, Max often doesn't.

The box is editable, the sample code is a placeholder that will be removed if you click in it and type.

Please drag a Debugger action into the On Submit event, then submit the form and post the debug results here.

Bob
seppo 24 May, 2016
Hi GreyHead,

OK, then it was not a bug🙂
I'm an old PHP programmer but had actually missed that optionality of PHP closing tag. Thanks for that!

I managed to get my form to work already (some problems still with another form and tcpdf but I will open another thread for that)

Thanks again for help! And for awesome products CF and CC!
This topic is locked and no more replies can be posted.