1<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 2 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 3<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" 4 lang="en" dir="ltr"> 5<head> 6 <title>filetype icons</title> 7 8 <style type="text/css"> 9 body { 10 background-color: #ccc; 11 font-family: Arial; 12 } 13 14 .box { 15 width: 200px; 16 float:left; 17 padding: 0.5em; 18 margin: 0; 19 } 20 21 .white { 22 background-color: #fff; 23 } 24 25 .black { 26 background-color: #000; 27 } 28 </style> 29 30</head> 31<body> 32 33<div class="white box"> 34<?php 35foreach (glob('*.png') as $img) { 36 echo '<img src="'.$img.'" alt="'.$img.'" title="'.$img.'" /> '; 37} 38?> 39</div> 40 41<div class="black box"> 42<?php 43foreach (glob('*.png') as $img) { 44 echo '<img src="'.$img.'" alt="'.$img.'" title="'.$img.'" /> '; 45} 46?> 47</div> 48 49</body> 50</html> 51