I need to upload files to a dir but before I do that I need to check that directory and count how many files with a particular extention I already have. If more then 5 do not show upload form if less allow upload.
How can I count, say PDF files, in my directory?