The scenario is that I am processing a large text file and moving each
line to one of a number of other files based on some criteria. I have
an array of file pointers with writable files. I have a limitation
where each of these subfiles can only contain a maximum of 8000
lines. Once I reach that mark, I would like to close the current file
pointer and open a new one with an integer increment appended to the
filename.
My problem is that once I have created these file pointers, how do I
then, for an arbitrary pointer, find out what path it points to?
Ideally, I would like to get the current path for the pointer, perform
some string manipulation to get me a new filename, then close it and
open the new file in it's place so that I can continue writing. Seems
like there should be some built-in php function to get the path for a
file pointer, but I can't find it. Anyone know of a way to get this
information?
Thanks,
- Moot