How can I Allow Users to Upload Files to My Website?

Please do not post me TechWalla’s article, I didn’t understand a thing.
Can someone who has PHP and HTML experience tell me how can I do such a thing, allow users to upload files to a specific folder in my website?

scripts on the site must be designed to produce web-based content
file storage scripts is not allowed

but if we talk about a pseudo code

then you should first ask the user for registration
(because you do not want to give access to some anonymous to upload something and go away)

after confirmation you need to have an interface through the user will browse files or drag and drop it from his computer

and when user click the upload button you need to check for the allowed extension, file size, etc.

if everything is okay “you” open the connection client > server
and allow the user to store file in a specific dir that is made for that purpose and uses certain modes.

you also need to generate a unique name for each file
so that it would not happen that two files had the same name (error)

then check it if everything is okay
and than give the user feedback information (error or OK)

It’s really simple,
what you’re going to need to do is understand how HTML forms work with PHP. Right?

Then, after that you’ll use the form input “file” to upload and use your PHP to explode, understand the files and then move it to your directory (mkdir for user specifics) and then check the file extension (handled with the explosions) then once it’s been transferred you end the upload process.

Here’s an example (this uploader use to offer free tutorials, now you have to pay -lame):