内容摘要:
?php//This will get an array of all the gif, jpg and png images in a folder$img_array = glob('/path/to/images/*.{gif,jpg,png}',GLOB_BRACE);//Pick a random image from the array$img ......
<?php
//This will get an array of all the gif, jpg and png images in a folder