What are common errors encountered when using PHP for file uploads?

One common error when using PHP for file uploads is exceeding the maximum file size allowed by the server. This can be solved by adjusting the `upload_max_filesize` and `post_max_size` directives in the php.ini file to allow larger file uploads.

// Adjust maximum file size allowed for uploads
ini_set('upload_max_filesize', '20M');
ini_set('post_max_size', '25M');