|
Posted by Martin Jay on 05/21/06 00:14
In message <446f5054@212.67.96.135>, "Dave (from the UK)"
<see-my-signature@southminster-branch-line.org.uk> writes
>In principle memory would do, but I've not had a lot of luck with it. I
>am using an external program and that is reading from a file.
>
>someprog -batchinput < /tmp/foo -batchoutput > /tmp/results
>
>When that reads from a pipe, the program behaves a little differently
>and a bit of an inconsistent way.
>
>I assume I can do something with a random number or time to get a
>unique name.
>
>In a shell script, I could do /tmp/foo.$$ and know that $$ will be the
>PID which will be unique. I would have thought php would have supported
>something like that.
You could use tempnam() or create a temporary filename with uniqid().
--
Martin Jay
Navigation:
[Reply to this message]
|