Messages - agentsteal [ switch to compact view ]

Pages: prev1 ... 5 6 7 8 9 [10]
46
I made you a PHP script :Thmbsup:

Code: PHP [Select]
  1. <?php
  2.  
  3. $folder = './';
  4. $subfolders = true;
  5. $extension = 'jpg';
  6. $orientation = 'L';
  7. $copytofolder = 'C:/Images/';
  8.  
  9. if (!is_dir ($folder))
  10. {
  11. echo ($folder . ' doesn\'t exist.');
  12. }
  13. elseif (!is_dir ($copytofolder))
  14. {
  15. echo ($copytofolder . ' doesn\'t exist.');
  16. }
  17. else
  18. {
  19. getImages ($folder, $subfolders, $extension, $orientation, $copytofolder);
  20. }
  21. function getImages ($folder, $subfolders, $extension, $orientation, $copytofolder)
  22. {
  23. $files = opendir ($folder);
  24. while ($image = readdir ($files))
  25. {
  26. if (is_dir ($folder . '/' . $image))
  27. {
  28. if ($subfolders && $image != '.' && $image != '..')
  29. {
  30. getImages ($folder . '/' . $image, $subfolders, $extension, $orientation, $copytofolder);
  31. }
  32. }
  33. elseif (substr ($image, -1 - strlen ($extension)) == '.' . $extension)
  34. {
  35. list ($width, $height) = getimagesize ($folder . '/' . $image);
  36. if (strtolower ($orientation) == 'p' && $height > $width)
  37. {
  38. echo ('Copying ' . $image . '...');
  39. fwrite (fopen ($copytofolder . '/' . $image, 'w'), file_get_contents ($folder . '/' . $image));
  40. }
  41. if (strtolower ($orientation) == 'l' && $height < $width)
  42. {
  43. echo ('Copying ' . $image . '...');
  44. fwrite (fopen ($copytofolder . '/' . $image, 'w'), file_get_contents ($folder . '/' . $image));
  45. }
  46. }
  47. }
  48. }
  49. ?>

47
Post New Requests Here / IDEA: DFT to GEDCOM converter
« on: December 16, 2007, 02:08 AM »
A GEDCOM is a file that contains family tree information. GEDCOM files can be loaded into most genealogy software.
Here is the GEDCOM format:
http://en.wikipedia.org/wiki/GEDCOM#Example

DFTCOM2 is a java program that converts a GEDCOM into a data file and shows the family tree in an applet.
http://www.dftcom2.co.uk/
Here is the DFT data file format:
http://www.dftcom2.co.uk/web/dftdbs.zip

Between 2003 and just last month, there have been many posts on the DFTCOM2 forum from people who have lost their original GEDCOM files and need a program to convert their DFTs to GEDCOM. However, the DFTCOM2 project was discontinued and no one ever made the converter.

This is a fairly simple project; it is mostly parsing information from one format to another and adding relationships between individuals. I was almost able to make the converter myself, but the numbers that determine the relationships are confusing. However, completing this project wouldn't take more than a day and would help a lot of people recover their family trees.

Pages: prev1 ... 5 6 7 8 9 [10]
Go to full version