Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Lesley 107 posts 349 karma points
    Jul 05, 2018 @ 01:13
    Lesley
    0

    File upload not working

    I have a form with a FileUpload field.

    When the form is submitted, the selected file is not saved to the media folder, or anywhere else that I can see. It's as though the submit process is just ignoring the file.

    enter image description here

    There are no errors in the log.

    Is there some special configuration that I need to do to get the FileUpload to work?

    I have also tried installing Perplex Form package and using their ImageUpload field but I have the same issue.

    EDIT: In FileUpload.ProcessSubmittedValue, context.Request.Files is null, but I don't know why...

    HttpFileCollectionBase files = context.Request.Files
    

    EDIT: I'm using WebForms, not MVC - could this be why?

  • Splinx 50 posts 186 karma points
    Aug 05, 2021 @ 15:14
    Splinx
    0

    Hi,

    I've got the exact same issue - can you please share if you fixed this and, if so, what the fix was.

    Thanks

  • Lesley 107 posts 349 karma points
    Sep 02, 2021 @ 23:28
    Lesley
    0

    Hi, Not entirely sure how I fixed it as it was a while ago.

    I did find this comment in our source control dated the day after my original post:

    " Added Razor layout pages as FileUpload only seems to work when FormPage is MVC based, not WebForms"

Please Sign in or register to post replies

Write your reply to:

Draft