Harrington
New Member
Hi all,
I have an error check in a PHP plugin set to OnBeforeProcess. This works correctly in the backend when submitting a form but not in the frontend. In the backend I get the error message displayed if the ftp transfer does not work. In the front end I get the message "Form Saved" popup.
Any ideas?
Many thanks in advance, Matt.
I have an error check in a PHP plugin set to OnBeforeProcess. This works correctly in the backend when submitting a form but not in the frontend. In the backend I get the error message displayed if the ftp transfer does not work. In the front end I get the message "Form Saved" popup.
Any ideas?
Many thanks in advance, Matt.
Code:
if (ftp_put($connect, $remoteFileName, $newFileName, FTP_ASCII))
{
return true;
} else {
$formModel->setFormErrorMsg("Cannot upload. Form not submitted");
return false;
}