<p>I want my php script to create an output file in a folder based on the date.  The way I'm doing this is that its supposed to get the foldername/filename from a text file outputted by another program which I am unable to edit.</p>

<p>So the file its grabbing the data from looks like this:</p>

<pre><code>data/newfolder/10302008/log_for_Today.txt | 24234234
</code></pre>

<p>Only with multiple lines, I just need the script to go through it line by line, grab the folder/filename and create an empty file with that name in that location.</p>

<p>The directories are all 777.  Now I know how to create a new empty exe file in a folder but can't seem to figure out how to create the folder first then the exe inside of it, any ideas?</p>

Can't you just do this by creating the dir with mkdir (
http://nl.php.net/manual/en/function.mkdir.php
) then chmod it 777 (
http://nl.php.net/manual/en/function.chmod.php
) the change directory with chdir (
http://nl.php.net/manual/en/function.chdir.php
) and then create the file (touch)?