我想支票夹,如果它包含PDF就会去其他的过程中,如果不包含PDF,它会跳过过程。 下面的代码:检查文件,如果不包含PDF它会跳过下一道工序
<?php
set_time_limit(0);
$savePath = 'D:/AppServ/www/aca/';
$dir = opendir($savePath);
$check = glob($savePath.'*.pdf');
if($check === ''){ exit();} // if not found pdf don't do process below this
// many other process below
?>
但过程中仍然运行,如何突破呢?谢谢:)
请记住,使用“文件扩展名”,以确定文件的类型是非常80ish ... – arkascha