Would someone be able to tell the easiest way to upload an image file to a server?

I have a form created with HTML and javascript with some text boxes and a file input type for uploading a file. When i click the submit button it sends the data to an aspx file which adds it to a database on the server. The filename for the image is stored in the database, but i also want to upload the image to a file on the server. How would i go about that?