46
Post New Requests Here / Re: IDEA: Find pics in required orientation on PC for digital frame
« on: December 16, 2007, 04:19 PM »
I made you a PHP script :Thmbsup:
Code: PHP [Select]
- <?php
- $folder = './';
- $subfolders = true;
- $extension = 'jpg';
- $orientation = 'L';
- $copytofolder = 'C:/Images/';
- {
- echo ($folder . ' doesn\'t exist.');
- }
- {
- echo ($copytofolder . ' doesn\'t exist.');
- }
- else
- {
- getImages ($folder, $subfolders, $extension, $orientation, $copytofolder);
- }
- function getImages ($folder, $subfolders, $extension, $orientation, $copytofolder)
- {
- {
- {
- if ($subfolders && $image != '.' && $image != '..')
- {
- getImages ($folder . '/' . $image, $subfolders, $extension, $orientation, $copytofolder);
- }
- }
- {
- {
- echo ('Copying ' . $image . '...');
- }
- {
- echo ('Copying ' . $image . '...');
- }
- }
- }
- }
- ?>