I'm writing a tool that allows someone to connect to a web page and generate files for download on the fly.
To write these files, I can use PHP functions like fopen or fwrite, or I could create a script that can be called as a system call to generate the output such as:
php downloadGen.php > filetocreate.xml
The fwrite version of the solution uses more memory and is also slower than the piped version. Does anyone see any problems with executing the download generation as a system call? Would there be a cap on how many calls I could be running simultaneously?
Anyway, I'm hoping someone has experience with something similar and can offer some advice...