Please follow the steps below
- In visual studio create a solution with empty web app with aspx project solution.
Create a file called index.aspx by adding a new item to the solution, in aspx page add the below code
- Add jquery plugin to <head> tag section
- Add HTML form fields to upload a file
- At bottom add the ajax file upload ajax script.
- After this create a File upload handler using generic handler(.ashx) by adding new item
- Here inside Process request add the below-written code.
- Then add FTP File upload below this process request function in .ashx. In FTP username and password section, please use your credentials.
For full project click on below button to download full demo solution.
I know this solution may not be the best, but it works for me, so if anyone knows the even easier solution please leave a link in the comment section below.