Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8409293
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T23:52:07+00:00 2026-06-09T23:52:07+00:00

Using Jquery Uploadify, I am not able to pass the file to the controller.

  • 0

Using Jquery Uploadify, I am not able to pass the file to the controller.

View :

       <input type="file" name="file_upload" id="file_upload" />

Jquery:

<script type="text/javascript">
    $(function () {

        var uploadUrl = $('#file_upload').data();

        $('#file_upload').uploadify({

            'auto': true,
            'script': uploadUrl,               
            'swf': 'Uploadify/uploadify.swf',
            'uploader': '/ControllerName/Upload',               
            'debug': true

        });
    }); 
</script>

Controller

  [HttpPost]
    public string Upload(HttpPostedFileBase file)
    {          
       //"file" = null is being passed from the view to the controller.
       //code..
    }

I am missing something, Thanks for your help.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T23:52:08+00:00Added an answer on June 9, 2026 at 11:52 pm

    You can use:

    [HttpPost]
    public string Upload(HttpPostedFileBase FileData) {
    }
    

    or

    [HttpPost]
    public ActionResult Upload() {
        if (Request.Files.Count > 0 && Request.Files[0].ContentLength > 0) {
            HttpPostedFileBase postedFile = Request.Files[0];
            // Do something with it
        }
    }
    

    If neither of these are working and your action isn’t firing at all (i.e. try debugging and see if a breakpoint within the method is hit), then your issue is most likely the ‘script’ value – are you running under a virtual directory? If so you’ll need to put the name of the directory in front. Uploadify is using an absolute path.

    You may also want to check the swf path, swf': 'Uploadify/uploadify.swf'. The way it is configured, it is relative to the current page. So if you were on localhost/Somepage it would be looking for /Somepage/Uploadify/uploadify.swf. You can check the browsers Network tab to ensure the uploadify.swf is not a 404

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to do below validations for single file uploaded using jQuery Uploadify
I have been using a jquery plugin called uploadify for handling file uploads as
I am using 'Uploadify' JQuery plugin for file upload. I read the documentation and
I'm using uploadify (jquery upload plugin) There is javascript $(#<%=ImageUpload.ClientID %>).uploadify({ 'uploader': '/Scripts/Plugins/uploadify/uploadify.swf', 'script':
Using an Uploadify and JGrowl combo: <link rel=stylesheet type=text/css href=css/default.css /><link rel=stylesheet type=text/css href=css/jgrowl.css
I'm using spring-mvc and jquery uploadify to upload an image, my uploadify script saves
I have a plugin for uploading files using jquery uploadify. After calling a method
I am using Jquery Uploadify for images upload with PHP, here i want to
I am using Jquery Uploadify for images upload with PHP, here i have multiple
I am using uploadify and my problem is that the files are not uploading.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.