Created
May 27, 2013 22:21
-
-
Save Niduroki/5659360 to your computer and use it in GitHub Desktop.
Picture testing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function ls($directory) { | |
$result = array(); | |
$handler = opendir($directory); | |
while ($file = readdir($handler)) { if ($file !== "." and $file !== "..") { $result[] = $file; } } | |
closedir($handler); | |
return $result; | |
} | |
?> | |
<!DOCTYPE html> | |
<html> | |
<head><title>Picture-test</title></head> | |
<body style="background-color: #aaa; text-align: center;"> | |
<?php | |
$core_css_images = ls("core/css/images/"); | |
$core_img_actions = ls("core/img/actions/"); | |
$core_img_places = ls("core/img/places/"); | |
$core_img_rating = ls("core/img/rating/"); | |
$core_img = ls("core/img/"); | |
$settings_img = ls("settings/img/"); | |
foreach($core_css_images as $image) { | |
echo('<img src="/core/css/images/'.$image.'"><br><br>'); | |
} | |
echo("<hr>"); | |
foreach($core_img_actions as $image) { | |
echo('<img src="/core/img/actions/'.$image.'"><br><br>'); | |
} | |
echo("<hr>"); | |
foreach($core_img_places as $image) { | |
echo('<img src="/core/img/places/'.$image.'"><br><br>'); | |
} | |
foreach($core_img_rating as $image) { | |
echo('<img src="/core/img/rating/'.$image.'"><br><br>'); | |
} | |
echo("<hr>"); | |
foreach($core_img as $image) { | |
echo('<img src="/core/img/'.$image.'"><br><br>'); | |
} | |
echo("<hr>"); | |
foreach($settings_img as $image) { | |
echo('<img src="/settings/img/'.$image.'"><br><br>'); | |
} | |
?> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment