Perch Forms - File submissions not saved if Spam

  • Hi,


    A website we manage uses perch forms and akismet to manage spam. They do however get some false-positives.


    In this instance, perch does not save files (it skips file submission if Spam is identified). I have attempted to adjusted the following code:


    Code
    1. if (!$spam && PerchUtil::count($SubmittedForm->files)) {


    by removing the "!$spam &&" part. This allows file submission partly (the file is added to the submission in the CMS, but it says "File not found" and doesn't actually save the file.


    If we ignore the potential security risks of allowing spammy files to be saved, is there a solution you can offer for enabling this functionality?

    Thanks!

  • drewm

    Approved the thread.
  • Matt,


    You can always create a modified version of the forms app which will save the files even if the submission is spam but it would be at the cost of losing any official support and would also make updating the app difficult when a newer version becomes available.


    Also, there is always a security risk with uploaded files, even if the submission isn't considered spam it could contain insecure content.