Usage: bash judge_prefix_string.sh TARGET_DIR TARGET_STR #!/bin/bash TARGET_DIR=$1 TARGET_STR=$2 ls $TARGET_DIR/$TARGET_STR* if [ $? -ne 0 ];then echo "file begin with $TARGET_STR is not existed!" else echo "file begin with $TARGET_STR is e
//JavaScript根据文件名判断文件类型 var imgExt = new Array(".png",".jpg",".jpeg",".bmp",".gif");//图片文件的后缀名 var docExt = new Array(".doc",".docx");//word文件的后缀名 var xlsExt = new Array(".xls"