Jump to content

Simulating $_FILES array


Recommended Posts

For uploading files, I use a class which accepts an uploaded file array, validates that it has a name, tmp_name, type, error, and size key, validates that it doesn't have errors and meets various requirements, and moves it to the applicable folder.

For another applicable, I will be generating the file directly on the server, however, wish to use this same class.  Will I need to manually create this "file" array, or is there a native PHP function to accept a path and automatically do it?

Thanks

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.