<?php $filenames = array('path/file.jpg','path/file.png','path/file.pdf'); foreach ($filenames as $filename) { if (preg_match('/^(?!.*\.pdf).*$/', $filename)) echo "\"$filename\" is not a PDF file.\n"; }
You have javascript disabled. You will not be able to edit any code.