gnu-social/plugins/Autocomplete/jquery-autocomplete/demo/images.php

10 lines
183 B
PHP
Raw Normal View History

2009-08-07 03:39:59 +09:00
<?php
$term = $_REQUEST['q'];
$images = array_slice(scandir("images"), 2);
foreach($images as $value) {
if( strpos(strtolower($value), $term) === 0 ) {
echo $value . "\n";
}
}
?>