PEAR Packages
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Codewalkers ForumsPHP RelatedPEAR Packages

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Codewalkers Forums Sponsor:
  #1  
Old July 28th, 2006, 05:52 PM
skypanther skypanther is offline
Codewalkers Newbie (0 - 499 posts)
 
Join Date: Apr 2007
Posts: 2 skypanther User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
File_Find returns an empty array

I've got some code that uses File_Find enumerate the contents of a directory tree and build a web page listing the contents in a tree format. The code works fine everywhere I've tested it except on one Windows 2003 Server box where it's returning an empty array. Other file system enumeration code works fine on that system, so it's not a permission issue. Here's a version of the code that's not working:

php Code:
Original - php Code
  1. ini_set('include_path', 'core');
  2. include "Find.php";
  3.  
  4. echo '<h2>Testing file output</h2><pre>';
  5. $dir = realpath(".");
  6. $dir = str_replace('c:\','/', $dir);
  7. $dir = str_replace('\','/', $dir);
  8. $files = File_Find::mapTreemultiple($dir, 2);
  9. print_r($files);
  10. echo '</pre>';


I'm not relying on any system-installed PEAR libs and instead am including my own in the core/ directory.

I'm using File_Find version: Find.php,v 1.27 2006/06/30 14:06:16

I'm using Pear.php $Id: PEAR.php,v 1.98 2006/01/23 05:38:05

Thanks,
Tim

Reply With Quote
  #2  
Old August 1st, 2006, 03:03 AM
lig's Avatar
lig lig is offline
"Forum Nazi"
Codewalkers Demi-God (4500 - 4999 posts)
 
Join Date: Apr 2007
Location: Jacksonville, Fl
Posts: 4,727 lig User rank is Private First Class (20 - 50 Reputation Level)lig User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 4 Days 1 h 4 m 45 sec
Reputation Power: 6
RE: File_Find returns an empty array

Where the other boxes *nix boxes? maybe it is using the *nix boxes glob program to find the files.

Reply With Quote
  #3  
Old August 1st, 2006, 01:55 PM
skypanther skypanther is offline
Codewalkers Newbie (0 - 499 posts)
 
Join Date: Apr 2007
Posts: 2 skypanther User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
RE: File_Find returns an empty array

It works on Windows 2000 w/IIS 5 and RH Linux w/Apache. It seems to work on some Windows Server 2003 systems but not all.

I've written other code to solve my needs. So, I'm not going to spend any more time getting the PEAR code to work. Thanks for your thoughts, though.

Tim

Reply With Quote
Reply

Viewing: Codewalkers ForumsPHP RelatedPEAR Packages > File_Find returns an empty array


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway