get directory iterator to start from the webroot

elated

New Member
My development and production sites written in php both need to use directory iterator in order to get at some files. Directory iterator starts at the base directory of the drive i.e c:/. However, on the dev and prod servers the webroot folder is located in a different place.Is there a way I can get directory iterator to start at the webroot. Or some similar method I can use so that I can use the same code on dev and prod without having to worry about where on the disk the application is stored.
 
Back
Top